From 0a5bd9f384dbbd5674c391ae0420e7593fcdc80d Mon Sep 17 00:00:00 2001 From: Sebastian Harl Date: Tue, 19 Feb 2008 12:24:53 +0100 Subject: [PATCH] hddtemp plugin: Use SCSI_DISK8_MAJOR thru SCSI_DISK15_MAJOR only if available. Some Linux versions don't seem to provide the major numbers 8 thru 15. Signed-off-by: Sebastian Harl Signed-off-by: Florian Forster --- src/hddtemp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/hddtemp.c b/src/hddtemp.c index 0a93920b..1047077d 100644 --- a/src/hddtemp.c +++ b/src/hddtemp.c @@ -304,6 +304,7 @@ static int hddtemp_init (void) case SCSI_DISK5_MAJOR: case SCSI_DISK6_MAJOR: case SCSI_DISK7_MAJOR: +#ifdef SCSI_DISK8_MAJOR case SCSI_DISK8_MAJOR: case SCSI_DISK9_MAJOR: case SCSI_DISK10_MAJOR: @@ -312,6 +313,7 @@ static int hddtemp_init (void) case SCSI_DISK13_MAJOR: case SCSI_DISK14_MAJOR: case SCSI_DISK15_MAJOR: +#endif /* SCSI_DISK8_MAJOR */ /* SCSI disks minors are multiples of 16. * Keep only those. */ if (minor % 16) -- 2.30.2