Changeset dd8ab1c in mainline
- Timestamp:
- 2017-12-10T21:08:11Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 68e5406
- Parents:
- 1afa94d
- Location:
- uspace
- Files:
-
- 19 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/bdsh/cmds/modules/cp/cp.c
r1afa94d rdd8ab1c 28 28 29 29 #include <errno.h> 30 #include <str_error.h> 30 31 #include <stdio.h> 31 32 #include <stdlib.h> … … 432 433 433 434 if (rc != EOK) { 434 printf("\nError copying %s , (%d)\n", src, rc);435 printf("\nError copying %s: %s\n", src, str_error(rc)); 435 436 return rc; 436 437 } -
uspace/app/bdsh/cmds/modules/ls/ls.c
r1afa94d rdd8ab1c 32 32 33 33 #include <errno.h> 34 #include <str_error.h> 34 35 #include <stdio.h> 35 36 #include <stdlib.h> … … 184 185 if (rc != EOK) { 185 186 printf("ls: skipping bogus node %s\n", buff); 186 printf("error=% d\n", rc);187 printf("error=%s\n", str_error_name(rc)); 187 188 goto out; 188 189 } -
uspace/app/bdsh/cmds/modules/mv/mv.c
r1afa94d rdd8ab1c 30 30 #include <stdlib.h> 31 31 #include <errno.h> 32 #include <str_error.h> 32 33 #include <vfs/vfs.h> 33 34 #include "config.h" … … 62 63 rc = vfs_rename_path(argv[1], argv[2]); 63 64 if (rc != EOK) { 64 printf("Unable to rename %s to %s (error=%d)\n",65 argv[1], argv[2], rc);65 printf("Unable to rename %s to %s: %s)\n", 66 argv[1], argv[2], str_error(rc)); 66 67 return CMD_FAILURE; 67 68 } -
uspace/app/bdsh/cmds/modules/unmount/unmount.c
r1afa94d rdd8ab1c 31 31 #include <vfs/vfs.h> 32 32 #include <errno.h> 33 #include <str_error.h> 33 34 #include "config.h" 34 35 #include "util.h" … … 68 69 rc = vfs_unmount_path(argv[1]); 69 70 if (rc != EOK) { 70 printf("Unable to unmount %s (rc=%d)\n", argv[1], rc);71 printf("Unable to unmount %s: %s\n", argv[1], str_error(rc)); 71 72 return CMD_FAILURE; 72 73 } -
uspace/drv/audio/hdaudio/codec.c
r1afa94d rdd8ab1c 37 37 #include <ddf/log.h> 38 38 #include <errno.h> 39 #include <str_error.h> 39 40 #include <stdlib.h> 40 41 … … 514 515 goto error; 515 516 516 ddf_msg(LVL_NOTE, "hda_get_subnc -> % d", rc);517 ddf_msg(LVL_NOTE, "hda_get_subnc -> %s", str_error_name(rc)); 517 518 ddf_msg(LVL_NOTE, "sfg=%d nfg=%d", sfg, nfg); 518 519 … … 524 525 goto error; 525 526 526 ddf_msg(LVL_NOTE, "hda_get_fgrp_type -> % d", rc);527 ddf_msg(LVL_NOTE, "hda_get_fgrp_type -> %s", str_error_name(rc)); 527 528 ddf_msg(LVL_NOTE, "unsol: %d, grptype: %d", unsol, grptype); 528 529 … … 546 547 goto error; 547 548 548 ddf_msg(LVL_NOTE, "hda_get_subnc -> % d", rc);549 ddf_msg(LVL_NOTE, "hda_get_subnc -> %s", str_error_name(rc)); 549 550 ddf_msg(LVL_NOTE, "saw=%d baw=%d", saw, naw); 550 551 -
uspace/drv/audio/hdaudio/hdaudio.c
r1afa94d rdd8ab1c 267 267 hdaudio_interrupt, &irq_code, &irq_cap); 268 268 if (rc != EOK) { 269 ddf_msg(LVL_ERROR, "Failed registering interrupt handler . (%d)",270 rc);269 ddf_msg(LVL_ERROR, "Failed registering interrupt handler: %s", 270 str_error_name(rc)); 271 271 goto error; 272 272 } … … 314 314 hw_res_list_parsed_clean(&res); 315 315 316 ddf_msg(LVL_NOTE, "Failing hda_dev_add() -> % d", rc);316 ddf_msg(LVL_NOTE, "Failing hda_dev_add() -> %s", str_error_name(rc)); 317 317 return rc; 318 318 } -
uspace/drv/audio/hdaudio/stream.c
r1afa94d rdd8ab1c 39 39 #include <ddi.h> 40 40 #include <errno.h> 41 #include <str_error.h> 41 42 #include <macros.h> 42 43 #include <stdlib.h> … … 122 123 0, &buffer_phys, &buffer); 123 124 if (rc != EOK) { 124 ddf_msg(LVL_NOTE, "dmamem_map_anon -> % d", rc);125 ddf_msg(LVL_NOTE, "dmamem_map_anon -> %s", str_error_name(rc)); 125 126 goto error; 126 127 } -
uspace/drv/char/ns8250/ns8250.c
r1afa94d rdd8ab1c 40 40 #include <stdio.h> 41 41 #include <errno.h> 42 #include <str_error.h> 42 43 #include <stdbool.h> 43 44 #include <fibril_synch.h> … … 887 888 if (rc != EOK) { 888 889 ddf_msg(LVL_ERROR, "Failed to enable the interrupt. Error code = " 889 "% d.", rc);890 "%s.", str_error_name(rc)); 890 891 goto fail; 891 892 } -
uspace/drv/char/pl050/pl050.c
r1afa94d rdd8ab1c 217 217 res.irqs.irqs[0], pl050_interrupt, &pl050_irq_code, &irq_cap); 218 218 if (rc != EOK) { 219 ddf_msg(LVL_ERROR, "Failed registering interrupt handler. (% d)",220 rc);219 ddf_msg(LVL_ERROR, "Failed registering interrupt handler. (%s)", 220 str_error_name(rc)); 221 221 goto error; 222 222 } -
uspace/drv/char/sun4v-con/sun4v-con.c
r1afa94d rdd8ab1c 36 36 #include <ddi.h> 37 37 #include <errno.h> 38 #include <str_error.h> 38 39 #include <io/chardev_srv.h> 39 40 #include <stdbool.h> … … 92 93 (void *) &con->input_buffer); 93 94 if (rc != EOK) { 94 ddf_msg(LVL_ERROR, "Error mapping memory: % d", rc);95 ddf_msg(LVL_ERROR, "Error mapping memory: %s", str_error_name(rc)); 95 96 goto error; 96 97 } … … 101 102 (void *) &con->output_buffer); 102 103 if (rc != EOK) { 103 ddf_msg(LVL_ERROR, "Error mapping memory: % d", rc);104 ddf_msg(LVL_ERROR, "Error mapping memory: %s", str_error_name(rc)); 104 105 return rc; 105 106 } -
uspace/drv/hid/ps2mouse/ps2mouse.c
r1afa94d rdd8ab1c 36 36 #include <stdbool.h> 37 37 #include <errno.h> 38 #include <str_error.h> 38 39 #include <ddf/log.h> 39 40 #include <io/keycode.h> … … 78 79 const int rc = chardev_read((mouse)->chardev, &data, 1, &nread); \ 79 80 if (rc != EOK) { \ 80 ddf_msg(LVL_ERROR, "Failed reading byte: % d", rc);\81 ddf_msg(LVL_ERROR, "Failed reading byte: %s", str_error_name(rc));\ 81 82 return rc; \ 82 83 } \ … … 95 96 const int rc = chardev_write((mouse)->chardev, &data, 1, &nwr); \ 96 97 if (rc != EOK) { \ 97 ddf_msg(LVL_ERROR, "Failed writing byte: % d", rc); \98 ddf_msg(LVL_ERROR, "Failed writing byte: %s", str_error_name(rc)); \ 98 99 return rc; \ 99 100 } \ -
uspace/drv/intctl/apic/apic.c
r1afa94d rdd8ab1c 221 221 rc = pio_enable((void *) res->base, IO_APIC_SIZE, ®s); 222 222 if (rc != EOK) { 223 printf("%s: Failed to enable PIO for APIC: % d\n", NAME, rc);223 printf("%s: Failed to enable PIO for APIC: %s\n", NAME, str_error(rc)); 224 224 return EIO; 225 225 } -
uspace/drv/nic/ar9271/ar9271.c
r1afa94d rdd8ab1c 42 42 #include <ddf/interrupt.h> 43 43 #include <errno.h> 44 #include <str_error.h> 44 45 #include <nic.h> 45 46 #include <macros.h> … … 784 785 free(buffer); 785 786 usb_log_error("Error while uploading firmware. " 786 "Error: % d\n", rc);787 "Error: %s\n", str_error_name(rc)); 787 788 return rc; 788 789 } … … 836 837 if (rc != EOK) { 837 838 usb_log_error("Failed to create USB device: %s, " 838 "ERR_NUM = % d\n", err_msg, rc);839 "ERR_NUM = %s\n", err_msg, str_error_name(rc)); 839 840 return NULL; 840 841 } … … 853 854 if (rc != EOK) { 854 855 free(ar9271); 855 usb_log_error("Failed to initialize AR9271 structure: % d\n",856 rc);856 usb_log_error("Failed to initialize AR9271 structure: %s\n", 857 str_error_name(rc)); 857 858 return NULL; 858 859 } -
uspace/drv/nic/ar9271/htc.c
r1afa94d rdd8ab1c 36 36 #include <byteorder.h> 37 37 #include <errno.h> 38 #include <str_error.h> 38 39 #include "wmi.h" 39 40 #include "htc.h" … … 264 265 if (rc != EOK) { 265 266 free(buffer); 266 usb_log_error("Failed to send HTC message. Error: % d\n", rc);267 usb_log_error("Failed to send HTC message. Error: %s\n", str_error_name(rc)); 267 268 return rc; 268 269 } … … 278 279 free(buffer); 279 280 usb_log_error("Failed to receive HTC service connect response. " 280 "Error: % d\n", rc);281 "Error: %s\n", str_error_name(rc)); 281 282 return rc; 282 283 } … … 331 332 free(buffer); 332 333 usb_log_error("Failed to send HTC config message. " 333 "Error: % d\n", rc);334 "Error: %s\n", str_error_name(rc)); 334 335 return rc; 335 336 } … … 344 345 if (rc != EOK) { 345 346 usb_log_error("Failed to receive HTC config response message. " 346 "Error: % d\n", rc);347 "Error: %s\n", str_error_name(rc)); 347 348 } 348 349 … … 376 377 if (rc != EOK) 377 378 usb_log_error("Failed to send HTC setup complete message. " 378 "Error: % d\n", rc);379 "Error: %s\n", str_error_name(rc)); 379 380 380 381 free(buffer); … … 404 405 free(buffer); 405 406 usb_log_error("Failed to receive HTC check ready message. " 406 "Error: % d\n", rc);407 "Error: %s\n", str_error_name(rc)); 407 408 return rc; 408 409 } -
uspace/drv/nic/ar9271/wmi.c
r1afa94d rdd8ab1c 35 35 #include <usb/debug.h> 36 36 #include <errno.h> 37 #include <str_error.h> 37 38 #include <stdlib.h> 38 39 #include <mem.h> … … 245 246 if (rc != EOK) { 246 247 free(buffer); 247 usb_log_error("Failed to send WMI message. Error: % d\n", rc);248 usb_log_error("Failed to send WMI message. Error: %s\n", str_error_name(rc)); 248 249 return rc; 249 250 } … … 268 269 free(buffer); 269 270 usb_log_error("Failed to receive WMI message response. " 270 "Error: % d\n", rc);271 "Error: %s\n", str_error_name(rc)); 271 272 return rc; 272 273 } -
uspace/drv/nic/rtl8169/driver.c
r1afa94d rdd8ab1c 30 30 #include <async.h> 31 31 #include <errno.h> 32 #include <str_error.h> 32 33 #include <align.h> 33 34 #include <byteorder.h> … … 430 431 rc = rtl8169_register_int_handler(nic_data, &irq_cap); 431 432 if (rc != EOK) { 432 ddf_msg(LVL_ERROR, "Failed to register IRQ handler (% d)", rc);433 ddf_msg(LVL_ERROR, "Failed to register IRQ handler (%s)", str_error_name(rc)); 433 434 goto err_irq; 434 435 } … … 706 707 rc = rtl8169_allocate_buffers(rtl8169); 707 708 if (rc != EOK) { 708 ddf_msg(LVL_ERROR, "Error allocating buffers: % d", rc);709 ddf_msg(LVL_ERROR, "Error allocating buffers: %s", str_error_name(rc)); 709 710 return 0; 710 711 } -
uspace/srv/hid/input/input.c
r1afa94d rdd8ab1c 827 827 int rc = loc_register_cat_change_cb(cat_change_cb); 828 828 if (rc != EOK) { 829 printf("%s: Failed registering callback for device discovery ."830 " (%d)\n", NAME, rc);829 printf("%s: Failed registering callback for device discovery: " 830 "%s\n", NAME, str_error(rc)); 831 831 return rc; 832 832 } -
uspace/srv/hid/rfb/rfb.c
r1afa94d rdd8ab1c 601 601 int rc = tcp_conn_send(conn, "RFB 003.008\n", 12); 602 602 if (rc != EOK) { 603 log_msg(LOG_DEFAULT, LVL_WARN, "Failed sending server version %d", rc); 603 log_msg(LOG_DEFAULT, LVL_WARN, "Failed sending server version: %s", 604 str_error(rc)); 604 605 return; 605 606 } … … 608 609 rc = recv_chars(conn, client_version, 12); 609 610 if (rc != EOK) { 610 log_msg(LOG_DEFAULT, LVL_WARN, "Failed receiving client version: %d", rc); 611 log_msg(LOG_DEFAULT, LVL_WARN, "Failed receiving client version: %s", 612 str_error(rc)); 611 613 return; 612 614 } … … 626 628 if (rc != EOK) { 627 629 log_msg(LOG_DEFAULT, LVL_WARN, 628 "Failed sending security handshake: % d", rc);630 "Failed sending security handshake: %s", str_error(rc)); 629 631 return; 630 632 } … … 633 635 rc = recv_char(conn, &selected_sec_type); 634 636 if (rc != EOK) { 635 log_msg(LOG_DEFAULT, LVL_WARN, "Failed receiving security type: %d", rc); 637 log_msg(LOG_DEFAULT, LVL_WARN, "Failed receiving security type: %s", 638 str_error(rc)); 636 639 return; 637 640 } … … 644 647 rc = tcp_conn_send(conn, &security_result, sizeof(uint32_t)); 645 648 if (rc != EOK) { 646 log_msg(LOG_DEFAULT, LVL_WARN, "Failed sending security result: %d", rc); 649 log_msg(LOG_DEFAULT, LVL_WARN, "Failed sending security result: %s", 650 str_error(rc)); 647 651 return; 648 652 } … … 652 656 rc = recv_char(conn, &shared_flag); 653 657 if (rc != EOK) { 654 log_msg(LOG_DEFAULT, LVL_WARN, "Failed receiving client init: %d", rc); 658 log_msg(LOG_DEFAULT, LVL_WARN, "Failed receiving client init: %s", 659 str_error(rc)); 655 660 return; 656 661 } … … 675 680 rc = tcp_conn_send(conn, server_init, msg_length); 676 681 if (rc != EOK) { 677 log_msg(LOG_DEFAULT, LVL_WARN, "Failed sending server init: %d", rc); 682 log_msg(LOG_DEFAULT, LVL_WARN, "Failed sending server init: %s", 683 str_error(rc)); 678 684 return; 679 685 } -
uspace/srv/volsrv/part.c
r1afa94d rdd8ab1c 329 329 rc = volsrv_part_empty(part->svc_id); 330 330 if (rc != EOK) { 331 log_msg(LOG_DEFAULT, LVL_DEBUG, "vol_part_empty_part() - failed % d",332 rc);331 log_msg(LOG_DEFAULT, LVL_DEBUG, "vol_part_empty_part() - failed %s", 332 str_error(rc)); 333 333 return rc; 334 334 } … … 349 349 rc = volsrv_part_mkfs(part->svc_id, fstype, label); 350 350 if (rc != EOK) { 351 log_msg(LOG_DEFAULT, LVL_DEBUG, "vol_part_mkfs_part() - failed % d",352 rc);351 log_msg(LOG_DEFAULT, LVL_DEBUG, "vol_part_mkfs_part() - failed %s", 352 str_error(rc)); 353 353 fibril_mutex_unlock(&vol_parts_lock); 354 354 return rc;
Note:
See TracChangeset
for help on using the changeset viewer.