| Date | Wed, 2 Feb 2005 11:50:20 +0900 | From | Tejun Heo <> | Subject | Re: [PATCH 2.6.11-rc2 8/29] ide: driver updates |
| |
> 08_ide_do_identify_model_string_termination.patch > > Terminates id->model string before invoking strstr() in > do_identify().
Signed-off-by: Tejun Heo <tj@home-tj.org>
Index: linux-ide-export/drivers/ide/ide-probe.c =================================================================== --- linux-ide-export.orig/drivers/ide/ide-probe.c 2005-02-02 10:27:15.858207205 +0900 +++ linux-ide-export/drivers/ide/ide-probe.c 2005-02-02 10:28:03.719442099 +0900 @@ -165,11 +165,12 @@ static inline void do_identify (ide_driv ide_fixstring(id->fw_rev, sizeof(id->fw_rev), bswap); ide_fixstring(id->serial_no, sizeof(id->serial_no), bswap); + /* we depend on this a lot! */ + id->model[sizeof(id->model)-1] = '\0'; + if (strstr(id->model, "E X A B Y T E N E S T")) goto err_misc; - /* we depend on this a lot! */ - id->model[sizeof(id->model)-1] = '\0'; printk("%s: %s, ", drive->name, id->model); drive->present = 1; drive->dead = 0; - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
|