Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=785955752fde4c555a1d9f74ddfe1f7aca3e0c7f Commit: 785955752fde4c555a1d9f74ddfe1f7aca3e0c7f Parent: b42fa133110fa952299fa76cbe91226c14838261 Author: Alan Cox <[EMAIL PROTECTED]> AuthorDate: Tue Jul 3 22:28:35 2007 +0200 Committer: Bartlomiej Zolnierkiewicz <[EMAIL PROTECTED]> CommitDate: Tue Jul 3 22:28:35 2007 +0200
ide: Fix a theoretical Ooops case Found by a static analyser. It is in theory possible we dereference dev->id when it has become invalid. Re-order to avoid this. Not needed for new-ide as we no longer support the crazy exabyte nest stuff Signed-off-by: Alan Cox <[EMAIL PROTECTED]> Cc: Andrew Morton <[EMAIL PROTECTED]> Signed-off-by: Bartlomiej Zolnierkiewicz <[EMAIL PROTECTED]> --- drivers/ide/ide-probe.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c index 41bfa4d..f5ce22c 100644 --- a/drivers/ide/ide-probe.c +++ b/drivers/ide/ide-probe.c @@ -574,11 +574,11 @@ static inline u8 probe_for_drive (ide_drive_t *drive) /* look for ATAPI device */ (void) do_probe(drive, WIN_PIDENTIFY); } - if (strstr(drive->id->model, "E X A B Y T E N E S T")) - enable_nest(drive); if (!drive->present) /* drive not found */ return 0; + if (strstr(drive->id->model, "E X A B Y T E N E S T")) + enable_nest(drive); /* identification failed? */ if (!drive->id_read) { - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html