aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2012-03-14 01:01:16 +0100
committerKay Sievers <kay.sievers@vrfy.org>2012-03-14 01:01:16 +0100
commit4b50a3d0048d13f6e37126f20f96e8bef262cbe2 (patch)
tree80ec5605e4f740460e41d13b5b5028ec108e9e19
parent746b5152cc15eb8c67bdfb5e17f8fc836cde9759 (diff)
downloadudev-4b50a3d0048d13f6e37126f20f96e8bef262cbe2.tar.gz
extras: ata_id - do not log error if HDIO_GET_IDENTITY fails
<tomegun> kay: is this a valid issue: https://bugs.archlinux.org/task/27060 ? <kay> tomegun: udev does not really care if that fails <tomegun> kay: the suggestion there is to treat EINVAL the same way we treat ENOTTY (i.e. as an info only) <tomegun> if it really does not matter it might make sense to avoid bogus bug reports <kay> tomegun: done
-rw-r--r--src/ata_id/ata_id.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/ata_id/ata_id.c b/src/ata_id/ata_id.c
index 257f4944..846a73b5 100644
--- a/src/ata_id/ata_id.c
+++ b/src/ata_id/ata_id.c
@@ -532,13 +532,8 @@ int main(int argc, char *argv[])
} else {
/* If this fails, then try HDIO_GET_IDENTITY */
if (ioctl(fd, HDIO_GET_IDENTITY, &id) != 0) {
- if (errno == ENOTTY) {
- info(udev, "HDIO_GET_IDENTITY unsupported for '%s'\n", node);
- rc = 2;
- } else {
- err(udev, "HDIO_GET_IDENTITY failed for '%s': %m\n", node);
- rc = 3;
- }
+ info(udev, "HDIO_GET_IDENTITY failed for '%s': %m\n", node);
+ rc = 2;
goto close;
}
}