pata_macio.c (c13aca79ff3c4af5fd31a5b2743a90eba6e36a26) | pata_macio.c (745d51dc8a29e00e9ba14e090aa3c8a41e7221d9) |
---|---|
1/* 2 * Libata based driver for Apple "macio" family of PATA controllers 3 * 4 * Copyright 2008/2009 Benjamin Herrenschmidt, IBM Corp 5 * <benh@kernel.crashing.org> 6 * 7 * Some bits and pieces from drivers/ide/ppc/pmac.c 8 * --- 469 unchanged lines hidden (view full) --- 478 priv->kind == controller_un_ata6 || 479 priv->kind == controller_k2_ata6 || 480 priv->kind == controller_sh_ata6) { 481 const char* cable = of_get_property(priv->node, "cable-type", 482 NULL); 483 struct device_node *root = of_find_node_by_path("/"); 484 const char *model = of_get_property(root, "model", NULL); 485 | 1/* 2 * Libata based driver for Apple "macio" family of PATA controllers 3 * 4 * Copyright 2008/2009 Benjamin Herrenschmidt, IBM Corp 5 * <benh@kernel.crashing.org> 6 * 7 * Some bits and pieces from drivers/ide/ppc/pmac.c 8 * --- 469 unchanged lines hidden (view full) --- 478 priv->kind == controller_un_ata6 || 479 priv->kind == controller_k2_ata6 || 480 priv->kind == controller_sh_ata6) { 481 const char* cable = of_get_property(priv->node, "cable-type", 482 NULL); 483 struct device_node *root = of_find_node_by_path("/"); 484 const char *model = of_get_property(root, "model", NULL); 485 |
486 of_node_put(root); 487 |
|
486 if (cable && !strncmp(cable, "80-", 3)) { 487 /* Some drives fail to detect 80c cable in PowerBook 488 * These machine use proprietary short IDE cable 489 * anyway 490 */ 491 if (!strncmp(model, "PowerBook", 9)) 492 return ATA_CBL_PATA40_SHORT; 493 else --- 925 unchanged lines hidden --- | 488 if (cable && !strncmp(cable, "80-", 3)) { 489 /* Some drives fail to detect 80c cable in PowerBook 490 * These machine use proprietary short IDE cable 491 * anyway 492 */ 493 if (!strncmp(model, "PowerBook", 9)) 494 return ATA_CBL_PATA40_SHORT; 495 else --- 925 unchanged lines hidden --- |