Changeset b16e77d in mainline for uspace/srv/bd/ata_bd/ata_bd.c
- Timestamp:
- 2012-06-01T19:14:43Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 50ad3f3
- Parents:
- 1038a9c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/bd/ata_bd/ata_bd.c
r1038a9c rb16e77d 191 191 } 192 192 193 printf( NAME ": Accepting connections\n");193 printf("%s: Accepting connections\n", NAME); 194 194 task_retval(0); 195 195 async_manager(); … … 243 243 static int ata_bd_init(void) 244 244 { 245 async_set_client_connection(ata_bd_connection); 246 int rc = loc_server_register(NAME); 247 if (rc != EOK) { 248 printf("%s: Unable to register driver.\n", NAME); 249 return rc; 250 } 251 245 252 void *vaddr; 246 int rc;247 248 async_set_client_connection(ata_bd_connection);249 rc = loc_server_register(NAME);250 if (rc < 0) {251 printf(NAME ": Unable to register driver.\n");252 return rc;253 }254 255 253 rc = pio_enable((void *) cmd_physical, sizeof(ata_cmd_t), &vaddr); 256 254 if (rc != EOK) { 257 printf( NAME ": Could not initialize device I/O space.\n");255 printf("%s: Could not initialize device I/O space.\n", NAME); 258 256 return rc; 259 257 } 260 258 261 259 cmd = vaddr; 262 260 263 261 rc = pio_enable((void *) ctl_physical, sizeof(ata_ctl_t), &vaddr); 264 262 if (rc != EOK) { 265 printf( NAME ": Could not initialize device I/O space.\n");263 printf("%s: Could not initialize device I/O space.\n", NAME); 266 264 return rc; 267 265 } 268 266 269 267 ctl = vaddr; 270 271 268 272 269 return EOK; 273 270 }
Note:
See TracChangeset
for help on using the changeset viewer.