Changes in / [694ca93f:042fbe0] in mainline


Ignore:
Files:
37 deleted
10 edited

Legend:

Unmodified
Added
Removed
  • boot/Makefile.common

    r694ca93f r042fbe0  
    9797        $(USPACE_PATH)/srv/fs/tmpfs/tmpfs \
    9898        $(USPACE_PATH)/srv/fs/fat/fat \
    99         $(USPACE_PATH)/srv/fs/pipefs/pipefs \
    100         $(USPACE_PATH)/srv/fs/ext2fs/ext2fs \
    10199        $(USPACE_PATH)/srv/taskmon/taskmon \
    102100        $(USPACE_PATH)/srv/hw/netif/ne2000/ne2000 \
     
    136134
    137135RD_APPS_NON_ESSENTIAL = \
    138         $(USPACE_PATH)/app/blkdump/blkdump \
    139136        $(USPACE_PATH)/app/dltest/dltest \
    140137        $(USPACE_PATH)/app/dltest2/dltest2 \
    141138        $(USPACE_PATH)/app/dload/dload \
    142139        $(USPACE_PATH)/app/edit/edit \
    143         $(USPACE_PATH)/app/ext2info/ext2info \
    144140        $(USPACE_PATH)/app/kill/kill \
    145141        $(USPACE_PATH)/app/killall/killall \
     
    149145        $(USPACE_PATH)/app/taskdump/taskdump \
    150146        $(USPACE_PATH)/app/tester/tester \
    151         $(USPACE_PATH)/app/testread/testread \
    152147        $(USPACE_PATH)/app/tetris/tetris \
    153148        $(USPACE_PATH)/app/trace/trace \
  • uspace/Makefile

    r694ca93f r042fbe0  
    3535DIRS = \
    3636        app/bdsh \
    37         app/blkdump \
    3837        app/edit \
    39         app/ext2info \
    4038        app/getterm \
    4139        app/init \
     
    4947        app/taskdump \
    5048        app/tester \
    51         app/testread \
    5249        app/tetris \
    5350        app/trace \
     
    7572        srv/fs/tmpfs \
    7673        srv/fs/devfs \
    77         srv/fs/pipefs \
    78         srv/fs/ext2fs \
    7974        srv/hid/adb_mouse \
    8075        srv/hid/char_mouse \
     
    153148        lib/drv \
    154149        lib/packet \
    155         lib/net \
    156         lib/ext2
     150        lib/net
    157151
    158152LIBC_BUILD = $(addsuffix .build,$(LIBC))
  • uspace/Makefile.common

    r694ca93f r042fbe0  
    108108LIBCLUI_PREFIX = $(LIB_PREFIX)/clui
    109109
    110 LIBEXT2_PREFIX = $(LIB_PREFIX)/ext2
    111 
    112110LIBDRV_PREFIX = $(LIB_PREFIX)/drv
    113111LIBPACKET_PREFIX = $(LIB_PREFIX)/packet
  • uspace/app/bdsh/cmds/modules/mount/mount.c

    r694ca93f r042fbe0  
    5151{
    5252        static char helpfmt[] =
    53             "Usage:  %s <fstype> <mp> [dev] [<moptions>]\n";
     53            "Usage:  %s <fstype> <mp> <dev> [<moptions>]\n";
    5454        if (level == HELP_SHORT) {
    5555                printf("'%s' mounts a file system.\n", cmdname);
     
    6666        unsigned int argc;
    6767        const char *mopts = "";
    68         const char *dev = "";
    6968        int rc, c, opt_ind;
    7069
     
    8079        }
    8180
    82         if ((argc < 3) || (argc > 5)) {
     81        if ((argc < 4) || (argc > 5)) {
    8382                printf("%s: invalid number of arguments. Try `mount --help'\n",
    8483                    cmdname);
    8584                return CMD_FAILURE;
    8685        }
    87         if (argc > 3)
    88                 dev = argv[3];
    8986        if (argc == 5)
    9087                mopts = argv[4];
    9188
    92         rc = mount(argv[1], argv[2], dev, mopts, 0);
     89        rc = mount(argv[1], argv[2], argv[3], mopts, 0);
    9390        if (rc != EOK) {
    9491                printf("Unable to mount %s filesystem to %s on %s (rc=%d)\n",
  • uspace/app/redir/redir.c

    r694ca93f r042fbe0  
    4949static void usage(void)
    5050{
    51         fprintf(stderr, "Usage: %s [-i <stdin>] [-o <stdout>] [-e <stderr>] -- <cmd> [args ...]\n",
     51        printf("Usage: %s [-i <stdin>] [-o <stdout>] [-e <stderr>] -- <cmd> [args ...]\n",
    5252            NAME);
    5353}
     
    8383        args = (const char **) calloc(argc + 1, sizeof(char *));
    8484        if (!args) {
    85                 fprintf(stderr, "No memory available\n");
     85                printf("No memory available\n");
    8686                return 0;
    8787        }
     
    9898       
    9999        if (rc != EOK) {
    100                 fprintf(stderr, "%s: Error spawning %s (%s)\n", NAME, argv[0],
     100                printf("%s: Error spawning %s (%s)\n", NAME, argv[0],
    101101                    str_error(rc));
    102                 return 0;
    103102        }
    104103       
  • uspace/app/tester/Makefile

    r694ca93f r042fbe0  
    2929
    3030USPACE_PREFIX = ../..
    31 LIBS = $(LIBBLOCK_PREFIX)/libblock.a $(LIBEXT2_PREFIX)/libext2.a
    32 EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) -I$(LIBEXT2_PREFIX)
    3331BINARY = tester
    3432
    3533SOURCES = \
    3634        tester.c \
    37         util.c \
    3835        thread/thread1.c \
    3936        print/print1.c \
     
    5552        devs/devman1.c \
    5653        hw/misc/virtchar1.c \
    57         hw/serial/serial1.c \
    58         libext2/libext2_1.c
     54        hw/serial/serial1.c
    5955
    6056include $(USPACE_PREFIX)/Makefile.common
  • uspace/app/tester/tester.c

    r694ca93f r042fbe0  
    6565#include "hw/serial/serial1.def"
    6666#include "hw/misc/virtchar1.def"
    67 #include "libext2/libext2_1.def"
    6867#include "devs/devman1.def"
    6968        {NULL, NULL, NULL, false}
  • uspace/app/tester/tester.h

    r694ca93f r042fbe0  
    8181extern const char *test_serial1(void);
    8282extern const char *test_virtchar1(void);
    83 extern const char *test_libext2_1(void);
    8483extern const char *test_devman1(void);
    8584
  • uspace/lib/block/libblock.c

    r694ca93f r042fbe0  
    22 * Copyright (c) 2008 Jakub Jermar
    33 * Copyright (c) 2008 Martin Decky
    4  * Copyright (c) 2011 Martin Sucha
    54 * All rights reserved.
    65 *
     
    828827}
    829828
    830 /** Read bytes directly from the device (bypass cache)
    831  *
    832  * @param devmap_handle Device handle of the block device.
    833  * @param abs_offset    Absolute offset in bytes where to start reading
    834  * @param bytes                 Number of bytes to read
    835  * @param data                  Buffer that receives the data
    836  *
    837  * @return              EOK on success or negative error code on failure.
    838  */
    839 int block_read_bytes_direct(devmap_handle_t devmap_handle, aoff64_t abs_offset,
    840     size_t bytes, void *data)
    841 {
    842         int rc;
    843         size_t phys_block_size;
    844         size_t buf_size;
    845         void *buffer;
    846         aoff64_t first_block;
    847         aoff64_t last_block;
    848         size_t blocks;
    849         size_t offset;
    850        
    851         rc = block_get_bsize(devmap_handle, &phys_block_size);
    852         if (rc != EOK) {
    853                 return rc;
    854         }
    855        
    856         // calculate data position and required space
    857         first_block = abs_offset / phys_block_size;
    858         offset = abs_offset % phys_block_size;
    859         last_block = (abs_offset + bytes - 1) / phys_block_size;
    860         blocks = last_block - first_block + 1;
    861         buf_size = blocks * phys_block_size;
    862        
    863         // read the data into memory
    864         buffer = malloc(buf_size);
    865         if (buffer == NULL) {
    866                 return ENOMEM;
    867         }
    868        
    869         rc = block_read_direct(devmap_handle, first_block, blocks, buffer);
    870         if (rc != EOK) {
    871                 free(buffer);
    872                 return rc;
    873         }
    874        
    875         // copy the data from the buffer
    876         memcpy(data, buffer + offset, bytes);
    877         free(buffer);
    878        
    879         return EOK;
    880 }
    881 
    882829/** Read blocks from block device.
    883830 *
  • uspace/lib/block/libblock.h

    r694ca93f r042fbe0  
    22 * Copyright (c) 2008 Jakub Jermar
    33 * Copyright (c) 2008 Martin Decky
    4  * Copyright (c) 2011 Martin Sucha
    54 * All rights reserved.
    65 *
     
    114113extern int block_get_nblocks(devmap_handle_t, aoff64_t *);
    115114extern int block_read_direct(devmap_handle_t, aoff64_t, size_t, void *);
    116 extern int block_read_bytes_direct(devmap_handle_t, aoff64_t, size_t, void *);
    117115extern int block_write_direct(devmap_handle_t, aoff64_t, size_t, const void *);
    118116
Note: See TracChangeset for help on using the changeset viewer.