diff options
Diffstat (limited to 'miscutils/hdparm.c')
-rw-r--r-- | miscutils/hdparm.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/miscutils/hdparm.c b/miscutils/hdparm.c index 342e240fa..b453efba9 100644 --- a/miscutils/hdparm.c +++ b/miscutils/hdparm.c | |||
@@ -810,7 +810,7 @@ static void identify(uint16_t *val) | |||
810 | like_std = 3; | 810 | like_std = 3; |
811 | } else | 811 | } else |
812 | /* "Unknown device type:\n\tbits 15&14 of general configuration word 0 both set to 1.\n" */ | 812 | /* "Unknown device type:\n\tbits 15&14 of general configuration word 0 both set to 1.\n" */ |
813 | bb_error_msg_and_die("unknown device type"); | 813 | bb_simple_error_msg_and_die("unknown device type"); |
814 | 814 | ||
815 | printf("%sremovable media\n", !(val[GEN_CONFIG] & MEDIA_REMOVABLE) ? "non-" : ""); | 815 | printf("%sremovable media\n", !(val[GEN_CONFIG] & MEDIA_REMOVABLE) ? "non-" : ""); |
816 | /* Info from the specific configuration word says whether or not the | 816 | /* Info from the specific configuration word says whether or not the |
@@ -1440,7 +1440,7 @@ static void flush_buffer_cache(/*int fd*/ void) | |||
1440 | sleep(1); | 1440 | sleep(1); |
1441 | if (ioctl(fd, HDIO_DRIVE_CMD, NULL) && errno != EINVAL) { /* await completion */ | 1441 | if (ioctl(fd, HDIO_DRIVE_CMD, NULL) && errno != EINVAL) { /* await completion */ |
1442 | if (ENABLE_IOCTL_HEX2STR_ERROR) /* To be coherent with ioctl_or_warn */ | 1442 | if (ENABLE_IOCTL_HEX2STR_ERROR) /* To be coherent with ioctl_or_warn */ |
1443 | bb_perror_msg("HDIO_DRIVE_CMD"); | 1443 | bb_simple_perror_msg("HDIO_DRIVE_CMD"); |
1444 | else | 1444 | else |
1445 | bb_perror_msg("ioctl %#x failed", HDIO_DRIVE_CMD); | 1445 | bb_perror_msg("ioctl %#x failed", HDIO_DRIVE_CMD); |
1446 | } | 1446 | } |
@@ -1506,7 +1506,7 @@ static void do_time(int cache /*,int fd*/) | |||
1506 | char *buf = xmalloc(TIMING_BUF_BYTES); | 1506 | char *buf = xmalloc(TIMING_BUF_BYTES); |
1507 | 1507 | ||
1508 | if (mlock(buf, TIMING_BUF_BYTES)) | 1508 | if (mlock(buf, TIMING_BUF_BYTES)) |
1509 | bb_perror_msg_and_die("mlock"); | 1509 | bb_simple_perror_msg_and_die("mlock"); |
1510 | 1510 | ||
1511 | /* Clear out the device request queues & give them time to complete. | 1511 | /* Clear out the device request queues & give them time to complete. |
1512 | * NB: *small* delay. User is expected to have a clue and to not run | 1512 | * NB: *small* delay. User is expected to have a clue and to not run |
@@ -1857,7 +1857,7 @@ static void process_dev(char *devname) | |||
1857 | char buf[512]; | 1857 | char buf[512]; |
1858 | flush_buffer_cache(); | 1858 | flush_buffer_cache(); |
1859 | if (-1 == read(fd, buf, sizeof(buf))) | 1859 | if (-1 == read(fd, buf, sizeof(buf))) |
1860 | bb_perror_msg("read of 512 bytes failed"); | 1860 | bb_simple_perror_msg("read of 512 bytes failed"); |
1861 | } | 1861 | } |
1862 | #endif /* HDIO_DRIVE_CMD */ | 1862 | #endif /* HDIO_DRIVE_CMD */ |
1863 | if (getset_mult || get_identity) { | 1863 | if (getset_mult || get_identity) { |
@@ -1865,7 +1865,7 @@ static void process_dev(char *devname) | |||
1865 | if (ioctl(fd, HDIO_GET_MULTCOUNT, &multcount)) { | 1865 | if (ioctl(fd, HDIO_GET_MULTCOUNT, &multcount)) { |
1866 | /* To be coherent with ioctl_or_warn. */ | 1866 | /* To be coherent with ioctl_or_warn. */ |
1867 | if (getset_mult && ENABLE_IOCTL_HEX2STR_ERROR) | 1867 | if (getset_mult && ENABLE_IOCTL_HEX2STR_ERROR) |
1868 | bb_perror_msg("HDIO_GET_MULTCOUNT"); | 1868 | bb_simple_perror_msg("HDIO_GET_MULTCOUNT"); |
1869 | else | 1869 | else |
1870 | bb_perror_msg("ioctl %#x failed", HDIO_GET_MULTCOUNT); | 1870 | bb_perror_msg("ioctl %#x failed", HDIO_GET_MULTCOUNT); |
1871 | } else if (getset_mult) { | 1871 | } else if (getset_mult) { |
@@ -1985,7 +1985,7 @@ static void process_dev(char *devname) | |||
1985 | } else if (errno == -ENOMSG) | 1985 | } else if (errno == -ENOMSG) |
1986 | puts(" no identification info available"); | 1986 | puts(" no identification info available"); |
1987 | else if (ENABLE_IOCTL_HEX2STR_ERROR) /* To be coherent with ioctl_or_warn */ | 1987 | else if (ENABLE_IOCTL_HEX2STR_ERROR) /* To be coherent with ioctl_or_warn */ |
1988 | bb_perror_msg("HDIO_GET_IDENTITY"); | 1988 | bb_simple_perror_msg("HDIO_GET_IDENTITY"); |
1989 | else | 1989 | else |
1990 | bb_perror_msg("ioctl %#x failed", HDIO_GET_IDENTITY); | 1990 | bb_perror_msg("ioctl %#x failed", HDIO_GET_IDENTITY); |
1991 | } | 1991 | } |