Changeset 6f9e7fea in mainline
- Timestamp:
- 2010-11-30T00:24:42Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 178673c
- Parents:
- 0ca16307
- Files:
-
- 4 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
boot/Makefile.common
r0ca16307 r6f9e7fea 109 109 110 110 RD_DRVS = \ 111 root 111 root \ 112 rootvirt 112 113 113 114 RD_DRV_CFG = -
uspace/Makefile
r0ca16307 r6f9e7fea 86 86 srv/net/tl/tcp \ 87 87 srv/net/net \ 88 drv/root 88 drv/root \ 89 drv/rootvirt 89 90 90 91 ## Networking -
uspace/drv/root/root.c
r0ca16307 r6f9e7fea 57 57 #define PLATFORM_DEVICE_MATCH_SCORE 100 58 58 59 #define VIRTUAL_DEVICE_NAME "virt" 60 #define VIRTUAL_DEVICE_MATCH_ID "rootvirt" 61 #define VIRTUAL_DEVICE_MATCH_SCORE 100 62 59 63 static int root_add_device(device_t *dev); 60 64 … … 69 73 .driver_ops = &root_ops 70 74 }; 75 76 /** Create the device which represents the root of virtual device tree. 77 * 78 * @param parent Parent of the newly created device. 79 * @return Error code. 80 */ 81 static int add_virtual_root_child(device_t *parent) 82 { 83 printf(NAME ": adding new child for virtual devices.\n"); 84 printf(NAME ": device node is `%s' (%d %s)\n", VIRTUAL_DEVICE_NAME, 85 VIRTUAL_DEVICE_MATCH_SCORE, VIRTUAL_DEVICE_MATCH_ID); 86 87 int res = child_device_register_wrapper(parent, VIRTUAL_DEVICE_NAME, 88 VIRTUAL_DEVICE_MATCH_ID, VIRTUAL_DEVICE_MATCH_SCORE); 89 90 return res; 91 } 71 92 72 93 /** Create the device which represents the root of HW device tree. … … 96 117 printf(NAME ": root_add_device, device handle = %d\n", dev->handle); 97 118 119 /* 120 * Register virtual devices root. 121 * We ignore error occurrence because virtual devices shall not be 122 * vital for the system. 123 */ 124 add_virtual_root_child(dev); 125 98 126 /* Register root device's children. */ 99 127 int res = add_platform_child(dev);
Note:
See TracChangeset
for help on using the changeset viewer.