Changes in / [9d653e3:72d120e] in mainline


Ignore:
Files:
9 added
234 deleted
51 edited

Legend:

Unmodified
Added
Removed
  • HelenOS.config

    r9d653e3 r72d120e  
    624624! CONFIG_BAREBONE (n/y)
    625625
    626 % Build pcc binaries
    627 ! CONFIG_PCC (n/y)
    628 
    629 % Build binutils binaries
    630 ! CONFIG_BINUTILS (n/y)
    631 
    632 % Build MSIM binary
    633 ! CONFIG_MSIM (n/y)
    634 
    635626% Line debugging information
    636627! [CONFIG_STRIP_BINARIES!=y] CONFIG_LINE_DEBUG (n/y)
  • Makefile

    r9d653e3 r72d120e  
    106106distclean: clean
    107107        rm -f $(CSCOPE).out $(COMMON_MAKEFILE) $(COMMON_HEADER) $(COMMON_HEADER_PREV) $(CONFIG_MAKEFILE) $(CONFIG_HEADER) tools/*.pyc tools/checkers/*.pyc release/HelenOS-*
    108         cd ./uspace/app/binutils/; ./distclean.sh
    109108
    110109clean:
  • boot/Makefile.common

    r9d653e3 r72d120e  
    219219        $(USPACE_PATH)/app/df/df
    220220
    221 ifeq ($(CONFIG_PCC),y)
    222 RD_APPS_NON_ESSENTIAL += \
    223         $(USPACE_PATH)/app/cc/cc \
    224         $(USPACE_PATH)/app/ccom/ccom \
    225         $(USPACE_PATH)/app/ccom/mkext/cc_mkext \
    226         $(USPACE_PATH)/app/cpp/cpp
    227 endif
    228 
    229 ifeq ($(CONFIG_BINUTILS),y)
    230 RD_APPS_NON_ESSENTIAL += \
    231         $(USPACE_PATH)/app/binutils/bin/as \
    232         $(USPACE_PATH)/app/binutils/bin/ld
    233 endif
    234 
    235 ifeq ($(CONFIG_MSIM),y)
    236 RD_APPS_NON_ESSENTIAL += \
    237         $(USPACE_PATH)/app/msim/msim
    238 endif
    239 
    240221COMPONENTS = \
    241222        $(KERNEL_PATH)/kernel.bin \
  • boot/arch/ia64/Makefile.inc

    r9d653e3 r72d120e  
    3131BFD_ARCH = ia64
    3232
    33 #
    34 # FIXME:
    35 #
    36 # The -fno-selective-scheduling and -fno-selective-scheduling2 options
    37 # should be removed as soon as a bug in GCC concerning unchecked
    38 # speculative loads is fixed.
    39 #
    40 # See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53975 for reference.
    41 #
    42 
    4333BITS = 64
    4434ENDIANESS = LE
    45 EXTRA_CFLAGS = -fno-unwind-tables -mfixed-range=f32-f127 -mno-pic -mno-sdata -fno-selective-scheduling -fno-selective-scheduling2
     35EXTRA_CFLAGS = -fno-unwind-tables -mfixed-range=f32-f127 -mno-pic -mno-sdata
    4636
    4737RD_SRVS_NON_ESSENTIAL +=
  • boot/genarch/src/ofw.c

    r9d653e3 r72d120e  
    377377            (map->cnt < MEMMAP_MAX_RECORDS); pos += ac + sc) {
    378378                void *start = (void *) (buf[pos + ac - 1]);
    379                 uint32_t size = buf[pos + ac + sc - 1];
     379                uintptr_t size = buf[pos + ac + sc - 1];
    380380               
    381381                /*
  • contrib/bazaar/bzreml/__init__.py

    r9d653e3 r72d120e  
    4040import smtplib
    4141import time
     42import os
    4243
    4344from StringIO import StringIO
     
    133134                                revision_ac_no = branch.revision_id_to_revno(revision_ac_id)
    134135                               
     136                                repo_name = os.path.basename(branch.base)
     137                                if (repo_name == ''):
     138                                        repo_name = os.path.basename(os.path.dirname(branch.base))
     139                               
    135140                                committer = revision_ac.committer
    136141                                authors = revision_ac.get_apparent_authors()
    137142                                date = time.strftime("%Y-%m-%d %H:%M:%S %Z (%a, %d %b %Y)", time.localtime(revision_ac.timestamp))
     143                               
     144                                body.write("Repo: %s\n" % repo_name)
    138145                               
    139146                                if (authors != [committer]):
     
    208215                                        tree_prev.unlock()
    209216                               
    210                                 subject = "r%d - %s" % (revision_ac_no, commit_message)
     217                                subject = "[%s] r%d - %s" % (repo_name, revision_ac_no, commit_message)
    211218                                send_smtp("localhost", config_sender(config), config_to(config), subject, body.getvalue())
    212219                               
  • contrib/bazaar/bzreml/setup.py

    r9d653e3 r72d120e  
    77        description = 'Commit email plugin for Bazaar',
    88        keywords = 'plugin bzr email',
    9         version = '1.3',
     9        version = '1.4',
    1010        url = 'http://www.decky.cz/',
    1111        license = 'BSD',
  • contrib/tools/random_check.sh

    r9d653e3 r72d120e  
    3838echo -n "">"$PRUNE_CONFIG_FILE"
    3939
    40 while getopts n:j:x:hsS option; do
     40while getopts n:j:x:hs option; do
    4141        case $option in
    4242        n)
     
    4949                echo "$OPTARG" | tr -d ' ' >>"$PRUNE_CONFIG_FILE"
    5050                ;;
    51         s|S)
     51        s)
    5252                echo "COMPILER=gcc_native" >>"$PRUNE_CONFIG_FILE"
    5353                echo "COMPILER=gcc_helenos" >>"$PRUNE_CONFIG_FILE"
    5454                echo "COMPILER=icc" >>"$PRUNE_CONFIG_FILE"
    55                 if [ "$option" = "S" ]; then
    56                         echo "CONFIG_PCC=y" >>"$PRUNE_CONFIG_FILE"
    57                         echo "CONFIG_BINUTILS=y" >>"$PRUNE_CONFIG_FILE"
    58                         echo "CONFIG_MSIM=y" >>"$PRUNE_CONFIG_FILE"
    59                 fi
    6055                ;;
    6156        *|h)
     
    7267                echo "      Use only supported compilers."
    7368                echo "      (That is, only GCC cross-compiler and Clang.)"
    74                 echo "  -S"
    75                 echo "      Build only reasonable configurations."
    76                 echo "      (Implies -s, does not build ported programs.)"
    7769                echo "  -x CONFIG_OPTION=value"
    7870                echo "      Skip the configuration if this option is present."
  • kernel/arch/ia64/Makefile.inc

    r9d653e3 r72d120e  
    3030BFD_ARCH = ia64-elf64
    3131
    32 #
    33 # FIXME:
    34 #
    35 # The -fno-selective-scheduling and -fno-selective-scheduling2 options
    36 # should be removed as soon as a bug in GCC concerning unchecked
    37 # speculative loads is fixed.
    38 #
    39 # See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53975 for reference.
    40 #
    41 
    42 CMN1 = -mconstant-gp -fno-unwind-tables -mfixed-range=f32-f127 -fno-selective-scheduling -fno-selective-scheduling2
     32CMN1 = -mconstant-gp -fno-unwind-tables -mfixed-range=f32-f127
    4333GCC_CFLAGS += $(CMN1)
    4434ICC_CFLAGS += $(CMN1)
  • kernel/arch/sparc64/src/drivers/niagara.c

    r9d653e3 r72d120e  
    208208         */
    209209       
     210        sysinfo_set_item_val("fb", NULL, true);
    210211        sysinfo_set_item_val("fb.kind", NULL, 5);
    211212       
  • kernel/generic/src/ddi/ddi.c

    r9d653e3 r72d120e  
    229229    void *virt_ptr, uintptr_t bound)
    230230{
    231         uintptr_t virt = (uintptr_t) -1;
    232         int rc = physmem_map(ALIGN_DOWN(phys, FRAME_SIZE), pages, flags,
    233             &virt, bound);
     231        uintptr_t virt;
     232        int rc = copy_from_uspace(&virt, virt_ptr, sizeof(virt));
     233        if (rc != EOK)
     234                return rc;
     235       
     236        rc = physmem_map(ALIGN_DOWN(phys, FRAME_SIZE), pages, flags, &virt,
     237            bound);
    234238        if (rc != EOK)
    235239                return rc;
     
    390394                        return rc;
    391395               
     396                uintptr_t virt;
     397                rc = copy_from_uspace(&virt, virt_ptr, sizeof(virt));
     398                if (rc != EOK)
     399                        return rc;
     400               
    392401                uintptr_t phys;
    393                 uintptr_t virt = (uintptr_t) -1;
    394402                rc = dmamem_map_anonymous(size, constraint, map_flags, flags,
    395403                    &phys, &virt, bound);
  • uspace/Makefile

    r9d653e3 r72d120e  
    156156        drv/nic/rtl8169
    157157
    158 ifeq ($(CONFIG_PCC),y)
    159 DIRS += \
    160         app/cc \
    161         app/ccom \
    162         app/ccom/mkext \
    163         app/cpp
    164 endif
    165 
    166 ifeq ($(CONFIG_BINUTILS),y)
    167 DIRS += \
    168         app/binutils
    169 endif
    170 
    171 ifeq ($(CONFIG_MSIM),y)
    172 DIRS += \
    173         app/msim
    174 endif
    175 
    176158## Platform-specific hardware support
    177159#
  • uspace/app/bdsh/compl.c

    r9d653e3 r72d120e  
    209209                *cstart += rpath_sep + 1 - prefix;
    210210                free(prefix);
     211                prefix = NULL;
    211212
    212213                cs->path_list = malloc(sizeof(char *) * 2);
     
    252253        }
    253254
    254         if (cs != NULL && cs->prefix != NULL)
     255        if ((cs != NULL) && (cs->prefix != NULL))
    255256                free(cs->prefix);
     257       
    256258        if (dirname != NULL)
    257259                free(dirname);
     260       
    258261        if (prefix != NULL)
    259262                free(prefix);
     263       
    260264        if (stext != NULL)
    261265                free(stext);
     266       
    262267        if (cs != NULL)
    263268                free(cs);
     269       
    264270        if (tokens != NULL)
    265271                free(tokens);
  • uspace/app/kio/kio.c

    r9d653e3 r72d120e  
    6363
    6464/* Pointer to kio area */
    65 static wchar_t *kio;
     65static wchar_t *kio = (wchar_t *) AS_AREA_ANY;
    6666static size_t kio_length;
    6767
  • uspace/app/vlaunch/vlaunch.c

    r9d653e3 r72d120e  
    4141#include <str.h>
    4242#include <str_error.h>
     43#include <loc.h>
     44#include <fibril_synch.h>
     45#include <io/pixel.h>
     46#include <device/led_dev.h>
    4347
    4448#include <window.h>
     
    6064#define LOGO_HEIGHT  66
    6165
     66#define PERIOD  1000000
     67#define COLORS  7
     68
    6269static char *winreg = NULL;
     70static fibril_timer_t *timer = NULL;
     71static list_t led_devs;
     72
     73static pixel_t colors[COLORS] = {
     74        PIXEL(0xff, 0xff, 0x00, 0x00),
     75        PIXEL(0xff, 0x00, 0xff, 0x00),
     76        PIXEL(0xff, 0x00, 0x00, 0xff),
     77        PIXEL(0xff, 0xff, 0xff, 0x00),
     78        PIXEL(0xff, 0xff, 0x00, 0xff),
     79        PIXEL(0xff, 0x00, 0xff, 0xff),
     80        PIXEL(0xff, 0xff, 0xff, 0xff)
     81};
     82
     83static unsigned int color = 0;
     84
     85typedef struct {
     86        link_t link;
     87        service_id_t svc_id;
     88        async_sess_t *sess;
     89} led_dev_t;
    6390
    6491static int app_launch(const char *app)
    6592{
    66         int rc;
    6793        printf("%s: Spawning %s %s \n", NAME, app, winreg);
    68 
     94       
    6995        task_id_t id;
    70         task_exit_t texit;
    71         int retval;
    72         rc = task_spawnl(&id, app, app, winreg, NULL);
     96        int rc = task_spawnl(&id, app, app, winreg, NULL);
    7397        if (rc != EOK) {
    7498                printf("%s: Error spawning %s %s (%s)\n", NAME, app,
     
    76100                return -1;
    77101        }
     102       
     103        task_exit_t texit;
     104        int retval;
    78105        rc = task_wait(id, &texit, &retval);
    79         if (rc != EOK || texit != TASK_EXIT_NORMAL) {
     106        if ((rc != EOK) || (texit != TASK_EXIT_NORMAL)) {
    80107                printf("%s: Error retrieving retval from %s (%s)\n", NAME,
    81108                    app, str_error(rc));
    82109                return -1;
    83110        }
    84 
     111       
    85112        return retval;
    86113}
     
    99126{
    100127        app_launch("/app/vlaunch");
     128}
     129
     130static void timer_callback(void *data)
     131{
     132        pixel_t next_color = colors[color];
     133       
     134        color++;
     135        if (color >= COLORS)
     136                color = 0;
     137       
     138        list_foreach(led_devs, link, led_dev_t, dev) {
     139                if (dev->sess)
     140                        led_dev_color_set(dev->sess, next_color);
     141        }
     142       
     143        fibril_timer_set(timer, PERIOD, timer_callback, NULL);
     144}
     145
     146static void loc_callback(void)
     147{
     148        category_id_t led_cat;
     149        int rc = loc_category_get_id("led", &led_cat, IPC_FLAG_BLOCKING);
     150        if (rc != EOK)
     151                return;
     152       
     153        service_id_t *svcs;
     154        size_t count;
     155        rc = loc_category_get_svcs(led_cat, &svcs, &count);
     156        if (rc != EOK)
     157                return;
     158       
     159        for (size_t i = 0; i < count; i++) {
     160                bool known = false;
     161               
     162                /* Determine whether we already know this device. */
     163                list_foreach(led_devs, link, led_dev_t, dev) {
     164                        if (dev->svc_id == svcs[i]) {
     165                                known = true;
     166                                break;
     167                        }
     168                }
     169               
     170                if (!known) {
     171                        led_dev_t *dev = (led_dev_t *) calloc(1, sizeof(led_dev_t));
     172                        if (!dev)
     173                                continue;
     174                       
     175                        link_initialize(&dev->link);
     176                        dev->svc_id = svcs[i];
     177                        dev->sess = loc_service_connect(EXCHANGE_SERIALIZE, svcs[i], 0);
     178                       
     179                        list_append(&dev->link, &led_devs);
     180                }
     181        }
     182       
     183        // FIXME: Handle LED device removal
     184       
     185        free(svcs);
    101186}
    102187
     
    105190        if (argc < 2) {
    106191                printf("Compositor server not specified.\n");
     192                return 1;
     193        }
     194       
     195        list_initialize(&led_devs);
     196        int rc = loc_register_cat_change_cb(loc_callback);
     197        if (rc != EOK) {
     198                printf("Unable to register callback for device discovery.\n");
     199                return 1;
     200        }
     201       
     202        timer = fibril_timer_create();
     203        if (!timer) {
     204                printf("Unable to create timer.\n");
    107205                return 1;
    108206        }
     
    163261        window_exec(main_window);
    164262       
     263        fibril_timer_set(timer, PERIOD, timer_callback, NULL);
     264       
    165265        task_retval(0);
    166266        async_manager();
  • uspace/drv/audio/sb16/dsp.c

    r9d653e3 r72d120e  
    178178       
    179179        uintptr_t pa = 0;
    180         void *buffer = NULL;
     180        void *buffer = AS_AREA_ANY;
    181181       
    182182        int ret = dmamem_map_anonymous(size, DMAMEM_16MiB | 0x0000ffff,
  • uspace/drv/block/ahci/ahci.c

    r9d653e3 r72d120e  
    234234       
    235235        uintptr_t phys;
    236         void *ibuf;
     236        void *ibuf = AS_AREA_ANY;
    237237        int rc = dmamem_map_anonymous(sata->block_size, DMAMEM_4GiB,
    238238            AS_AREA_READ | AS_AREA_WRITE, 0, &phys, &ibuf);
     
    277277       
    278278        uintptr_t phys;
    279         void *ibuf;
     279        void *ibuf = AS_AREA_ANY;
    280280        int rc = dmamem_map_anonymous(sata->block_size, DMAMEM_4GiB,
    281281            AS_AREA_READ | AS_AREA_WRITE, 0, &phys, &ibuf);
     
    436436       
    437437        uintptr_t phys;
    438         sata_identify_data_t *idata;
     438        sata_identify_data_t *idata = AS_AREA_ANY;
    439439        int rc = dmamem_map_anonymous(SATA_IDENTIFY_DEVICE_BUFFER_LENGTH,
    440440            DMAMEM_4GiB, AS_AREA_READ | AS_AREA_WRITE, 0, &phys,
    441             (void **) &idata);
     441            (void *) &idata);
    442442        if (rc != EOK) {
    443443                ddf_msg(LVL_ERROR, "Cannot allocate buffer to identify device.");
     
    630630       
    631631        uintptr_t phys;
    632         sata_identify_data_t *idata;
     632        sata_identify_data_t *idata = AS_AREA_ANY;
    633633        int rc = dmamem_map_anonymous(SATA_SET_FEATURE_BUFFER_LENGTH,
    634634            DMAMEM_4GiB, AS_AREA_READ | AS_AREA_WRITE, 0, &phys,
    635             (void **) &idata);
     635            (void *) &idata);
    636636        if (rc != EOK) {
    637637                ddf_msg(LVL_ERROR, "Cannot allocate buffer for device set mode.");
     
    938938        size_t size = 4096;
    939939        uintptr_t phys = 0;
    940         void *virt_fb = NULL;
    941         void *virt_cmd = NULL;
    942         void *virt_table = NULL;
     940        void *virt_fb = AS_AREA_ANY;
     941        void *virt_cmd = AS_AREA_ANY;
     942        void *virt_table = AS_AREA_ANY;
    943943        ddf_fun_t *fun;
    944944       
     
    11551155       
    11561156        /* Map AHCI registers. */
    1157         ahci->memregs = NULL;
     1157        ahci->memregs = AS_AREA_ANY;
    11581158       
    11591159        physmem_map(RNGABS(hw_res_parsed.mem_ranges.ranges[0]),
    11601160            AHCI_MEMREGS_PAGES_COUNT, AS_AREA_READ | AS_AREA_WRITE,
    1161             (void **) &ahci->memregs);
     1161            (void *) &ahci->memregs);
    11621162        if (ahci->memregs == NULL)
    11631163                goto error_map_registers;
  • uspace/drv/bus/usb/uhci/utils/malloc32.h

    r9d653e3 r72d120e  
    103103{
    104104        uintptr_t phys;
    105         void *address;
     105        void *address = AS_AREA_ANY;
    106106       
    107107        const int ret = dmamem_map_anonymous(UHCI_REQUIRED_PAGE_SIZE,
  • uspace/drv/bus/usb/usbhid/Makefile

    r9d653e3 r72d120e  
    5050        mouse/mousedev.c \
    5151        multimedia/multimedia.c \
    52         multimedia/keymap.c
     52        multimedia/keymap.c \
     53        blink1/blink1.c
    5354
    5455SOURCES = \
  • uspace/drv/bus/usb/usbhid/generic/hiddev.c

    r9d653e3 r72d120e  
    4949#include "usbhid.h"
    5050
    51 
    52 
    5351const usb_endpoint_description_t usb_hid_generic_poll_endpoint_description = {
    5452        .transfer_type = USB_TRANSFER_INTERRUPT,
     
    6159
    6260const char *HID_GENERIC_FUN_NAME = "hid";
    63 const char *HID_GENERIC_CLASS_NAME = "hid";
     61const char *HID_GENERIC_CATEGORY = "hid";
    6462
    6563
     
    226224        return true;
    227225}
     226
    228227/**
    229228 * @}
  • uspace/drv/bus/usb/usbhid/generic/hiddev.h

    r9d653e3 r72d120e  
    3838
    3939#include <usb/dev/driver.h>
    40 
    41 struct usb_hid_dev;
     40#include "../usbhid.h"
    4241
    4342extern const usb_endpoint_description_t
    4443    usb_hid_generic_poll_endpoint_description;
    4544
    46 const char *HID_GENERIC_FUN_NAME;
    47 const char *HID_GENERIC_CLASS_NAME;
     45extern const char *HID_GENERIC_FUN_NAME;
     46extern const char *HID_GENERIC_CATEGORY;
    4847
    4948/** The USB HID generic 'hid' function softstate */
    5049typedef struct {
    51         struct usb_hid_dev *hid_dev;
     50        usb_hid_dev_t *hid_dev;
    5251} usb_hid_gen_fun_t;
    5352
    54 int usb_generic_hid_init(struct usb_hid_dev *hid_dev, void **data);
    55 
    56 void usb_generic_hid_deinit(struct usb_hid_dev *hid_dev, void *data);
    57 
    58 bool usb_generic_hid_polling_callback(struct usb_hid_dev *hid_dev, void *data);
     53extern int usb_generic_hid_init(usb_hid_dev_t *, void **);
     54extern void usb_generic_hid_deinit(usb_hid_dev_t *, void *);
     55extern bool usb_generic_hid_polling_callback(usb_hid_dev_t *, void *);
    5956
    6057#endif // USB_HID_HIDDDEV_H_
  • uspace/drv/bus/usb/usbhid/kbd/kbddev.c

    r9d653e3 r72d120e  
    103103
    104104const char *HID_KBD_FUN_NAME = "keyboard";
    105 const char *HID_KBD_CATEGORY_NAME = "keyboard";
     105const char *HID_KBD_CATEGORY = "keyboard";
    106106
    107107static void usb_kbd_set_led(usb_hid_dev_t *hid_dev, usb_kbd_t *kbd_dev);
     
    513513
    514514        usb_log_debug("Adding DDF function to category %s...\n",
    515             HID_KBD_CLASS_NAME);
    516         rc = ddf_fun_add_to_category(fun, HID_KBD_CATEGORY_NAME);
     515            HID_KBD_CATEGORY);
     516        rc = ddf_fun_add_to_category(fun, HID_KBD_CATEGORY);
    517517        if (rc != EOK) {
    518518                usb_log_error(
    519519                    "Could not add DDF function to category %s: %s.\n",
    520                     HID_KBD_CLASS_NAME, str_error(rc));
     520                    HID_KBD_CATEGORY, str_error(rc));
    521521                if (ddf_fun_unbind(fun) == EOK) {
    522522                        ddf_fun_destroy(fun);
  • uspace/drv/bus/usb/usbhid/kbd/kbddev.h

    r9d653e3 r72d120e  
    4545#include <usb/dev/pipes.h>
    4646#include <usb/dev/driver.h>
    47 
     47#include "../usbhid.h"
    4848#include "kbdrepeat.h"
    49 
    50 struct usb_hid_dev;
    51 
    5249
    5350/**
     
    6562typedef struct usb_kbd_t {
    6663        /** Link to HID device structure */
    67         struct usb_hid_dev *hid_dev;
    68 
     64        usb_hid_dev_t *hid_dev;
     65       
    6966        /** Previously pressed keys (not translated to key codes). */
    7067        int32_t *keys_old;
     
    7572        /** Currently pressed modifiers (bitmap). */
    7673        uint8_t modifiers;
    77 
     74       
    7875        /** Currently active modifiers including locks. Sent to the console. */
    79         unsigned mods;
    80 
     76        unsigned int mods;
     77       
    8178        /** Currently active lock keys. */
    82         unsigned lock_keys;
    83 
     79        unsigned int lock_keys;
     80       
    8481        /** IPC session to client (for sending key events). */
    8582        async_sess_t *client_sess;
    86 
     83       
    8784        /** Information for auto-repeat of keys. */
    8885        usb_kbd_repeat_t repeat;
    89 
     86       
    9087        /** Mutex for accessing the information about auto-repeat. */
    9188        fibril_mutex_t repeat_mtx;
    92 
     89       
    9390        uint8_t *output_buffer;
    94 
     91       
    9592        size_t output_size;
    96 
     93       
    9794        size_t led_output_size;
    98 
     95       
    9996        usb_hid_report_path_t *led_path;
    100 
     97       
    10198        int32_t *led_data;
    102 
     99       
    103100        /** State of the structure (for checking before use).
    104          * 
     101         *
    105102         * 0 - not initialized
    106103         * 1 - initialized
     
    108105         */
    109106        int initialized;
    110 
     107       
    111108        /** DDF function */
    112109        ddf_fun_t *fun;
    113110} usb_kbd_t;
    114111
    115 
    116 
    117112extern const usb_endpoint_description_t usb_hid_kbd_poll_endpoint_description;
    118113
    119 const char *HID_KBD_FUN_NAME;
    120 const char *HID_KBD_CLASS_NAME;
     114extern const char *HID_KBD_FUN_NAME;
     115extern const char *HID_KBD_CATEGORY;
    121116
    122 
    123 
    124 int usb_kbd_init(struct usb_hid_dev *hid_dev, void **data);
    125 
    126 bool usb_kbd_polling_callback(struct usb_hid_dev *hid_dev, void *data);
    127 
    128 int usb_kbd_is_initialized(const usb_kbd_t *kbd_dev);
    129 
    130 int usb_kbd_is_ready_to_destroy(const usb_kbd_t *kbd_dev);
    131 
    132 void usb_kbd_destroy(usb_kbd_t *kbd_dev);
    133 
    134 void usb_kbd_push_ev(usb_kbd_t *kbd_dev,
    135     int type, unsigned int key);
    136 
    137 void usb_kbd_deinit(struct usb_hid_dev *hid_dev, void *data);
    138 
    139 int usb_kbd_set_boot_protocol(struct usb_hid_dev *hid_dev);
     117extern int usb_kbd_init(usb_hid_dev_t *, void **);
     118extern bool usb_kbd_polling_callback(usb_hid_dev_t *, void *);
     119extern int usb_kbd_is_initialized(const usb_kbd_t *);
     120extern int usb_kbd_is_ready_to_destroy(const usb_kbd_t *);
     121extern void usb_kbd_destroy(usb_kbd_t *);
     122extern void usb_kbd_push_ev(usb_kbd_t *, int, unsigned int);
     123extern void usb_kbd_deinit(usb_hid_dev_t *, void *);
     124extern int usb_kbd_set_boot_protocol(usb_hid_dev_t *);
    140125
    141126#endif /* USB_HID_KBDDEV_H_ */
  • uspace/drv/bus/usb/usbhid/mouse/mousedev.c

    r9d653e3 r72d120e  
    344344
    345345        if (hid_dev == NULL) {
    346                 usb_log_error("Failed to init keyboard structure: no structure"
     346                usb_log_error("Failed to init mouse structure: no structure"
    347347                    " given.\n");
    348348                return EINVAL;
  • uspace/drv/bus/usb/usbhid/mouse/mousedev.h

    r9d653e3 r72d120e  
    3939#include <usb/dev/driver.h>
    4040#include <async.h>
    41 
    42 struct usb_hid_dev;
    43 
    44 
     41#include "../usbhid.h"
    4542
    4643/** Container for USB mouse device. */
     
    4845        /** IPC session to consumer. */
    4946        async_sess_t *mouse_sess;
    50 
    51         /* Mouse buttons statuses. */
     47       
     48        /** Mouse buttons statuses. */
    5249        int32_t *buttons;
    5350        size_t buttons_count;
    54 
    55         /* DDF mouse function */
     51       
     52        /** DDF mouse function */
    5653        ddf_fun_t *mouse_fun;
    5754} usb_mouse_t;
    5855
    59 
    60 
    6156extern const usb_endpoint_description_t usb_hid_mouse_poll_endpoint_description;
    6257
    63 const char *HID_MOUSE_FUN_NAME;
    64 const char *HID_MOUSE_CATEGORY;
     58extern const char *HID_MOUSE_FUN_NAME;
     59extern const char *HID_MOUSE_CATEGORY;
    6560
    66 
    67 
    68 int usb_mouse_init(struct usb_hid_dev *hid_dev, void **data);
    69 
    70 bool usb_mouse_polling_callback(struct usb_hid_dev *hid_dev, void *data);
    71 
    72 void usb_mouse_deinit(struct usb_hid_dev *hid_dev, void *data);
    73 
    74 int usb_mouse_set_boot_protocol(struct usb_hid_dev *hid_dev);
    75 
    76 
     61extern int usb_mouse_init(usb_hid_dev_t *, void **);
     62extern bool usb_mouse_polling_callback(usb_hid_dev_t *, void *);
     63extern void usb_mouse_deinit(usb_hid_dev_t *, void *);
     64extern int usb_mouse_set_boot_protocol(usb_hid_dev_t *);
    7765
    7866#endif // USB_HID_MOUSEDEV_H_
  • uspace/drv/bus/usb/usbhid/multimedia/multimedia.c

    r9d653e3 r72d120e  
    11/*
    2  * Copyright (c) 2011 Lubos Slovak, Vojtech Horky
     2 * Copyright (c) 2011 Lubos Slovak
     3 * Copyright (c) 2011 Vojtech Horky
    34 * All rights reserved.
    45 *
  • uspace/drv/bus/usb/usbhid/multimedia/multimedia.h

    r9d653e3 r72d120e  
    3838
    3939#include <usb/dev/driver.h>
     40#include "../usbhid.h"
    4041
    41 struct usb_hid_dev;
    42 
    43 
    44 
    45 int usb_multimedia_init(struct usb_hid_dev *hid_dev, void **data);
    46 
    47 void usb_multimedia_deinit(struct usb_hid_dev *hid_dev, void *data);
    48 
    49 bool usb_multimedia_polling_callback(struct usb_hid_dev *hid_dev, void *data);
    50 
    51 
     42extern int usb_multimedia_init(usb_hid_dev_t *, void **);
     43extern void usb_multimedia_deinit(usb_hid_dev_t *, void *);
     44extern bool usb_multimedia_polling_callback(usb_hid_dev_t *, void *);
    5245
    5346#endif // USB_HID_MULTIMEDIA_H_
  • uspace/drv/bus/usb/usbhid/subdrivers.c

    r9d653e3 r72d120e  
    3737#include <usb/hid/usages/core.h>
    3838#include <usb/hid/hidpath.h>
    39 
     39#include "kbd/kbddev.h"
     40#include "mouse/mousedev.h"
    4041#include "multimedia/multimedia.h"
    41 #include "mouse/mousedev.h"
     42#include "blink1/blink1.h"
    4243#include "generic/hiddev.h"
    4344
    4445static const usb_hid_subdriver_usage_t path_kbd[] = {
    45         {USB_HIDUT_PAGE_GENERIC_DESKTOP,
    46          USB_HIDUT_USAGE_GENERIC_DESKTOP_KEYBOARD},
     46        {
     47                USB_HIDUT_PAGE_GENERIC_DESKTOP,
     48                USB_HIDUT_USAGE_GENERIC_DESKTOP_KEYBOARD
     49        },
    4750        {0, 0}
    4851};
    4952
    5053static const usb_hid_subdriver_usage_t path_mouse[] = {
    51         {USB_HIDUT_PAGE_GENERIC_DESKTOP, USB_HIDUT_USAGE_GENERIC_DESKTOP_MOUSE},
     54        {
     55                USB_HIDUT_PAGE_GENERIC_DESKTOP,
     56                USB_HIDUT_USAGE_GENERIC_DESKTOP_MOUSE
     57        },
    5258        {0, 0}
    5359};
    5460
    55 static const usb_hid_subdriver_usage_t multim_key_path[] = {
    56         {USB_HIDUT_PAGE_CONSUMER, USB_HIDUT_USAGE_CONSUMER_CONSUMER_CONTROL},
     61static const usb_hid_subdriver_usage_t path_multim_key[] = {
     62        {
     63                USB_HIDUT_PAGE_CONSUMER,
     64                USB_HIDUT_USAGE_CONSUMER_CONSUMER_CONTROL
     65        },
    5766        {0, 0}
    5867};
     
    7382        },
    7483        {
    75                 multim_key_path,
     84                path_multim_key,
    7685                1,
    7786                USB_HID_PATH_COMPARE_BEGIN,
     
    98107                }
    99108        },
     109        {
     110                NULL,
     111                0,
     112                USB_HID_PATH_COMPARE_BEGIN,
     113                0x27b8,
     114                0x01ed,
     115                {
     116                        .init = usb_blink1_init,
     117                        .deinit = usb_blink1_deinit,
     118                        .poll = NULL,
     119                        .poll_end = NULL
     120                }
     121        }
    100122};
    101123
  • uspace/drv/bus/usb/usbhid/subdrivers.h

    r9d653e3 r72d120e  
    4040#include "kbd/kbddev.h"
    4141
    42 
    43 
    4442typedef struct usb_hid_subdriver_usage {
    4543        int usage_page;
     
    4745} usb_hid_subdriver_usage_t;
    4846
    49 
    50 
    51 /** Structure representing the mapping between device requirements and the
     47/** Structure representing the mapping between device requirements and the
    5248 *  subdriver supposed to handle this device.
    5349 *
     
    5551 * a new subdriver mapping will be created and used by the HID driver when it
    5652 * searches for appropriate subdrivers for a device.
     53 *
    5754 */
    5855typedef struct usb_hid_subdriver_mapping {
    59         /** Usage path that the device's Input reports must contain.
     56        /** Usage path that the device's input reports must contain.
    6057         *
    6158         * It is an array of pairs <usage_page, usage>, terminated by a <0, 0>
     
    6461         */
    6562        const usb_hid_subdriver_usage_t *usage_path;
    66 
     63       
    6764        /** Report ID for which the path should apply. */
    6865        int report_id;
    69 
    70         /** Compare type for the Usage path. */
     66       
     67        /** Compare type for the usage path. */
    7168        int compare;
    72 
     69       
    7370        /** Vendor ID (set to -1 if not specified). */
    7471        int vendor_id;
    75 
     72       
    7673        /** Product ID (set to -1 if not specified). */
    7774        int product_id;
    78 
     75       
    7976        /** Subdriver for controlling this device. */
    8077        const usb_hid_subdriver_t subdriver;
    8178} usb_hid_subdriver_mapping_t;
    8279
    83 
    84 
    8580extern const usb_hid_subdriver_mapping_t usb_hid_subdrivers[];
    8681extern const size_t USB_HID_MAX_SUBDRIVERS;
    87 
    88 
    8982
    9083#endif /* USB_HID_SUBDRIVERS_H_ */
  • uspace/drv/bus/usb/usbhid/usbhid.ma

    r9d653e3 r72d120e  
    1 100 usb&interface&class=HID&subclass=0x01&protocol=0x01
     11000 usb&interface&class=HID&subclass=0x01&protocol=0x01
    221000 usb&interface&class=HID&subclass=0x01&protocol=0x02
    33100 usb&interface&class=HID
  • uspace/drv/fb/amdm37x_dispc/amdm37x_dispc.c

    r9d653e3 r72d120e  
    3838#include <ddf/log.h>
    3939#include <ddi.h>
    40 #include <abi/mm/as.h>
     40#include <as.h>
    4141
    4242#include "amdm37x_dispc.h"
     
    274274        const size_t size = ALIGN_UP(x * y * bpp, PAGE_SIZE);
    275275        uintptr_t pa;
    276         void *buffer;
     276        void *buffer = AS_AREA_ANY;
    277277        int ret = dmamem_map_anonymous(size, DMAMEM_4GiB,
    278278            AS_AREA_READ | AS_AREA_WRITE, 0, &pa, &buffer);
  • uspace/drv/fb/kfb/port.c

    r9d653e3 r72d120e  
    333333       
    334334        kfb.size = scanline * height;
     335        kfb.addr = AS_AREA_ANY;
     336       
    335337        rc = physmem_map(paddr + offset,
    336338            ALIGN_UP(kfb.size, PAGE_SIZE) >> PAGE_WIDTH,
  • uspace/drv/nic/e1k/e1k.c

    r9d653e3 r72d120e  
    13751375        fibril_mutex_lock(&e1000->rx_lock);
    13761376       
     1377        e1000->rx_ring_virt = AS_AREA_ANY;
    13771378        int rc = dmamem_map_anonymous(
    13781379            E1000_RX_FRAME_COUNT * sizeof(e1000_rx_descriptor_t),
     
    13961397        }
    13971398       
    1398         size_t i;
    1399         uintptr_t frame_phys;
    1400         void *frame_virt;
    1401        
    1402         for (i = 0; i < E1000_RX_FRAME_COUNT; i++) {
     1399        for (size_t i = 0; i < E1000_RX_FRAME_COUNT; i++) {
     1400                uintptr_t frame_phys;
     1401                void *frame_virt = AS_AREA_ANY;
     1402               
    14031403                rc = dmamem_map_anonymous(E1000_MAX_SEND_FRAME_SIZE,
    14041404                    DMAMEM_4GiB, AS_AREA_READ | AS_AREA_WRITE, 0,
     
    14121412       
    14131413        /* Write descriptor */
    1414         for (i = 0; i < E1000_RX_FRAME_COUNT; i++)
     1414        for (size_t i = 0; i < E1000_RX_FRAME_COUNT; i++)
    14151415                e1000_fill_new_rx_descriptor(nic, i);
    14161416       
     
    14211421       
    14221422error:
    1423         for (i = 0; i < E1000_RX_FRAME_COUNT; i++) {
     1423        for (size_t i = 0; i < E1000_RX_FRAME_COUNT; i++) {
    14241424                if (e1000->rx_frame_virt[i] != NULL) {
    14251425                        dmamem_unmap_anonymous(e1000->rx_frame_virt[i]);
     
    15711571       
    15721572        e1000->tx_ring_phys = 0;
    1573         e1000->tx_ring_virt = NULL;
     1573        e1000->tx_ring_virt = AS_AREA_ANY;
    15741574       
    15751575        e1000->tx_frame_phys = NULL;
     
    15971597       
    15981598        for (i = 0; i < E1000_TX_FRAME_COUNT; i++) {
     1599                e1000->tx_frame_virt[i] = AS_AREA_ANY;
    15991600                rc = dmamem_map_anonymous(E1000_MAX_SEND_FRAME_SIZE,
    16001601                    DMAMEM_4GiB, AS_AREA_READ | AS_AREA_WRITE,
  • uspace/drv/nic/rtl8139/driver.c

    r9d653e3 r72d120e  
    11411141
    11421142        ddf_msg(LVL_DEBUG, "Creating buffers");
    1143 
     1143       
     1144        rtl8139->tx_buff_virt = AS_AREA_ANY;
    11441145        rc = dmamem_map_anonymous(TX_PAGES * PAGE_SIZE, DMAMEM_4GiB,
    11451146            AS_AREA_WRITE, 0, &rtl8139->tx_buff_phys, &rtl8139->tx_buff_virt);
     
    11611162        ddf_msg(LVL_DEBUG, "Allocating receiver buffer of the size %d bytes",
    11621163            RxBUF_TOT_LENGTH);
    1163 
     1164       
     1165        rtl8139->rx_buff_virt = AS_AREA_ANY;
    11641166        rc = dmamem_map_anonymous(RxBUF_TOT_LENGTH, DMAMEM_4GiB,
    11651167            AS_AREA_READ, 0, &rtl8139->rx_buff_phys, &rtl8139->rx_buff_virt);
  • uspace/lib/c/Makefile

    r9d653e3 r72d120e  
    6565        generic/device/pio_window.c \
    6666        generic/device/clock_dev.c \
     67        generic/device/led_dev.c \
    6768        generic/dhcp.c \
    6869        generic/dnsr.c \
  • uspace/lib/c/arch/ia64/Makefile.common

    r9d653e3 r72d120e  
    2727#
    2828
    29 #
    30 # FIXME:
    31 #
    32 # The -fno-selective-scheduling and -fno-selective-scheduling2 options
    33 # should be removed as soon as a bug in GCC concerning unchecked
    34 # speculative loads is fixed.
    35 #
    36 # See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53975 for reference.
    37 #
    38 
    39 GCC_CFLAGS += -fno-unwind-tables -fno-selective-scheduling -fno-selective-scheduling2
     29GCC_CFLAGS += -fno-unwind-tables
    4030
    4131ENDIANESS = LE
  • uspace/lib/c/arch/sparc64/_link.ld.in

    r9d653e3 r72d120e  
    1010#endif
    1111        data PT_LOAD FLAGS(6);
     12        debug PT_NOTE;
    1213}
    1314
     
    6364        } :data
    6465       
     66#ifdef CONFIG_LINE_DEBUG
     67        .comment 0 : { *(.comment); } :debug
     68        .debug_abbrev 0 : { *(.debug_abbrev); } :debug
     69        .debug_aranges 0 : { *(.debug_aranges); } :debug
     70        .debug_info 0 : { *(.debug_info); } :debug
     71        .debug_line 0 : { *(.debug_line); } :debug
     72        .debug_loc 0 : { *(.debug_loc); } :debug
     73        .debug_pubnames 0 : { *(.debug_pubnames); } :debug
     74        .debug_pubtypes 0 : { *(.debug_pubtypes); } :debug
     75        .debug_ranges 0 : { *(.debug_ranges); } :debug
     76        .debug_str 0 : { *(.debug_str); } :debug
     77#endif
     78       
    6579        /DISCARD/ : {
    6680                *(*);
  • uspace/lib/c/generic/ddi.c

    r9d653e3 r72d120e  
    7171 * @param flags Flags for the new address space area.
    7272 * @param virt  Virtual address of the starting page.
    73  *
    74  * @return EOK on success
    75  * @return EPERM if the caller lacks the CAP_MEM_MANAGER capability
    76  * @return ENOENT if there is no task with specified ID
     73 *              If set to AS_AREA_ANY ((void *) -1), a suitable value
     74 *              is found by the kernel, otherwise the kernel tries to
     75 *              obey the desired value.
     76 *
     77 * @return EOK on success.
     78 * @return EPERM if the caller lacks the CAP_MEM_MANAGER capability.
    7779 * @return ENOMEM if there was some problem in creating
    7880 *         the address space area.
     
    8587}
    8688
     89/** Lock a piece physical memory for DMA transfers.
     90 *
     91 * The mapping of the specified virtual memory address
     92 * to physical memory address is locked in order to
     93 * make it safe for DMA transferts.
     94 *
     95 * Caller of this function must have the CAP_MEM_MANAGER capability.
     96 *
     97 * @param virt      Virtual address of the memory to be locked.
     98 * @param size      Number of bytes to lock.
     99 * @param map_flags Desired virtual memory area flags.
     100 * @param flags     Flags for the physical memory address.
     101 * @param phys      Locked physical memory address.
     102 *
     103 * @return EOK on success.
     104 * @return EPERM if the caller lacks the CAP_MEM_MANAGER capability.
     105 * @return ENOMEM if there was some problem in creating
     106 *         the address space area.
     107 *
     108 */
    87109int dmamem_map(void *virt, size_t size, unsigned int map_flags,
    88110    unsigned int flags, uintptr_t *phys)
     
    93115}
    94116
     117/** Map a piece of physical memory suitable for DMA transfers.
     118 *
     119 * Caller of this function must have the CAP_MEM_MANAGER capability.
     120 *
     121 * @param size       Number of bytes to map.
     122 * @param constraint Bit mask defining the contraint on the physical
     123 *                   address to be mapped.
     124 * @param map_flags  Desired virtual memory area flags.
     125 * @param flags      Flags for the physical memory address.
     126 * @param virt       Virtual address of the starting page.
     127 *                   If set to AS_AREA_ANY ((void *) -1), a suitable value
     128 *                   is found by the kernel, otherwise the kernel tries to
     129 *                   obey the desired value.
     130 *
     131 * @return EOK on success.
     132 * @return EPERM if the caller lacks the CAP_MEM_MANAGER capability.
     133 * @return ENOMEM if there was some problem in creating
     134 *         the address space area.
     135 *
     136 */
    95137int dmamem_map_anonymous(size_t size, uintptr_t constraint,
    96138    unsigned int map_flags, unsigned int flags, uintptr_t *phys, void **virt)
     
    221263        size_t pages = SIZE2PAGES(offset + size);
    222264       
    223         void *virt_page;
     265        void *virt_page = AS_AREA_ANY;
    224266        int rc = physmem_map(phys_frame, pages,
    225267            AS_AREA_READ | AS_AREA_WRITE, &virt_page);
  • uspace/lib/c/generic/device/clock_dev.c

    r9d653e3 r72d120e  
    2727 */
    2828
    29  /** @addtogroup libc
     29/** @addtogroup libc
    3030 * @{
    3131 */
  • uspace/lib/c/generic/time.c

    r9d653e3 r72d120e  
    555555                }
    556556               
    557                 void *addr;
     557                void *addr = AS_AREA_ANY;
    558558                rc = physmem_map(faddr, 1, AS_AREA_READ | AS_AREA_CACHEABLE,
    559559                    &addr);
  • uspace/lib/c/include/ipc/dev_iface.h

    r9d653e3 r72d120e  
    6565        CLOCK_DEV_IFACE,
    6666
     67        /** Interface provided by LED devices */
     68        LED_DEV_IFACE,
     69
    6770        /** Interface provided by battery powered devices */
    6871        BATTERY_DEV_IFACE,
  • uspace/lib/drv/Makefile

    r9d653e3 r72d120e  
    5454        generic/remote_usbhid.c \
    5555        generic/remote_clock_dev.c \
     56        generic/remote_led_dev.c \
    5657        generic/remote_battery_dev.c \
    5758        generic/remote_ahci.c
  • uspace/lib/drv/generic/dev_iface.c

    r9d653e3 r72d120e  
    4343#include "remote_char_dev.h"
    4444#include "remote_clock_dev.h"
     45#include "remote_led_dev.h"
    4546#include "remote_battery_dev.h"
    4647#include "remote_graph_dev.h"
     
    6869                [USBHID_DEV_IFACE] = &remote_usbhid_iface,
    6970                [CLOCK_DEV_IFACE] = &remote_clock_dev_iface,
     71                [LED_DEV_IFACE] = &remote_led_dev_iface,
    7072                [BATTERY_DEV_IFACE] = &remote_battery_dev_iface,
    7173                [AHCI_DEV_IFACE] = &remote_ahci_iface,
  • uspace/lib/drv/generic/remote_usbhc.c

    r9d653e3 r72d120e  
    363363static void async_transaction_destroy(async_transaction_t *trans)
    364364{
    365         if (trans == NULL) {
    366                 return;
    367         }
    368         if (trans->buffer != NULL) {
     365        if (trans == NULL)
     366                return;
     367       
     368        if (trans->buffer != NULL)
    369369                free(trans->buffer);
    370         }
    371 
     370       
    372371        free(trans);
    373372}
     
    585584                async_answer_0(callid, ENOMEM);
    586585                async_transaction_destroy(trans);
     586                return;
    587587        }
    588588
  • uspace/srv/bd/rd/rd.c

    r9d653e3 r72d120e  
    6060
    6161/** Pointer to the ramdisk's image */
    62 static void *rd_addr;
     62static void *rd_addr = AS_AREA_ANY;
    6363
    6464/** Size of the ramdisk */
  • uspace/srv/hid/input/port/niagara.c

    r9d653e3 r72d120e  
    7474        uint64_t read_ptr;
    7575        char data[INPUT_BUFFER_SIZE];
    76 }
    77         __attribute__ ((packed))
    78         __attribute__ ((aligned(PAGE_SIZE)))
    79         *input_buffer_t;
     76} __attribute__((packed)) __attribute__((aligned(PAGE_SIZE))) *input_buffer_t;
    8077
    8178/* virtual address of the shared buffer */
    82 static input_buffer_t input_buffer;
     79static input_buffer_t input_buffer = (input_buffer_t) AS_AREA_ANY;
    8380
    8481static volatile bool polling_disabled = false;
     
    8784/**
    8885 * Initializes the Niagara driver.
    89  * Maps the shared buffer and creates the polling thread. 
     86 * Maps the shared buffer and creates the polling thread.
    9087 */
    9188static int niagara_port_init(kbd_dev_t *kdev)
  • uspace/srv/hid/output/port/ega.c

    r9d653e3 r72d120e  
    215215       
    216216        ega.size = (ega.cols * ega.rows) << 1;
     217        ega.addr = AS_AREA_ANY;
    217218       
    218219        rc = physmem_map(paddr,
  • uspace/srv/hid/output/port/kchar.c

    r9d653e3 r72d120e  
    8484                return rc;
    8585       
     86        kchar.addr = AS_AREA_ANY;
     87       
    8688        rc = physmem_map(paddr,
    8789            ALIGN_UP(1, PAGE_SIZE) >> PAGE_WIDTH,
  • uspace/srv/hid/output/port/niagara.c

    r9d653e3 r72d120e  
    104104                return rc;
    105105       
     106        niagara.fifo = (output_fifo_t *) AS_AREA_ANY;
     107       
    106108        rc = physmem_map(paddr, 1, AS_AREA_READ | AS_AREA_WRITE,
    107109            (void *) &niagara.fifo);
  • uspace/srv/hw/irc/obio/obio.c

    r9d653e3 r72d120e  
    7070
    7171static uintptr_t base_phys;
    72 static volatile uint64_t *base_virt;
     72static volatile uint64_t *base_virt = (volatile uint64_t *) AS_AREA_ANY;
    7373
    7474/** Handle one connection to obio.
  • uspace/srv/locsrv/locsrv.c

    r9d653e3 r72d120e  
    320320                svc_categ_t *memb = list_get_instance(link, svc_categ_t,
    321321                    svc_link);
    322                 fibril_mutex_lock(&memb->cat->mutex);
     322                category_t *cat = memb->cat;
     323               
     324                fibril_mutex_lock(&cat->mutex);
    323325                category_remove_service(memb);
    324                 fibril_mutex_unlock(&memb->cat->mutex);
     326                fibril_mutex_unlock(&cat->mutex);
    325327        }
    326328       
     
    13301332
    13311333        cat = category_new("mouse");
     1334        categ_dir_add_cat(&cdir, cat);
     1335
     1336        cat = category_new("led");
    13321337        categ_dir_add_cat(&cdir, cat);
    13331338
Note: See TracChangeset for help on using the changeset viewer.