[oe-commits] t.fromm : linux-2.6.24: fix kernel oops upon driver unload for hipox machine
git version control
git at git.openembedded.org
Thu Mar 11 12:44:42 UTC 2010
Module: openembedded.git
Branch: shr/unstable
Commit: 20f3db21f3b7cc50d2c661e98596d366428c348b
URL: http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=20f3db21f3b7cc50d2c661e98596d366428c348b
Author: t.fromm <t.fromm at ba11ecae-741b-462f-8724-1218f99f5906>
Date: Thu Mar 4 15:26:20 2010 +0000
linux-2.6.24: fix kernel oops upon driver unload for hipox machine
Signed-off-by: Thilo Fromm <t.fromm at dresearch.de>
Acked-by: Steffen Sledz <sledz at dresearch.de>
---
recipes/linux/linux-2.6.24/hipox/hipox.patch | 28 +++++++++++++++++++++----
1 files changed, 23 insertions(+), 5 deletions(-)
diff --git a/recipes/linux/linux-2.6.24/hipox/hipox.patch b/recipes/linux/linux-2.6.24/hipox/hipox.patch
index cd944e7..c99ef51 100644
--- a/recipes/linux/linux-2.6.24/hipox/hipox.patch
+++ b/recipes/linux/linux-2.6.24/hipox/hipox.patch
@@ -32006,10 +32006,10 @@ diff -Nurd linux-2.6.24.4/drivers/ata/ox800sata.c linux-2.6.24/drivers/ata/ox800
+EXPORT_SYMBOL( hipoxsata_RAID_faults );
+EXPORT_SYMBOL( hipoxsata_get_port_no );
+EXPORT_SYMBOL( hipoxsata_LBA_schemes_compatible );
-diff -Nurd linux-2.6.24.4/drivers/ata/ox810sata.c linux-2.6.24/drivers/ata/ox810sata.c
---- linux-2.6.24.4/drivers/ata/ox810sata.c 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.6.24/drivers/ata/ox810sata.c 2010-01-14 14:01:15.000000000 +0100
-@@ -0,0 +1,2423 @@
+diff -Nurd linux-2.6.24/drivers/ata/ox810sata.c linux-2.6.24-oxe810/drivers/ata/ox810sata.c
+--- linux-2.6.24/drivers/ata/ox810sata.c 1970-01-01 01:00:00.000000000 +0100
++++ linux-2.6.24-oxe810/drivers/ata/ox810sata.c 2008-06-11 17:50:32.000000000 +0200
+@@ -0,0 +1,2441 @@
+/**************************************************************************
+ *
+ * Copyright (c) 2007 Oxford Semiconductor Ltd.
@@ -32447,12 +32447,30 @@ diff -Nurd linux-2.6.24.4/drivers/ata/ox810sata.c linux-2.6.24/drivers/ata/ox810
+{
+ struct ata_host *host_set = dev_get_drvdata( &(pdev->dev) );
+ struct ata_port *ap;
-+ unsigned int i;
++ unsigned int i,j;
+
++ /* tfm: detach host driver */
++ ata_host_detach(host_set);
++
+ for (i = 0; i < host_set->n_ports; i++)
+ {
++ struct ata_port *p=NULL;
+ ap = host_set->ports[i];
+ scsi_remove_host( ap->scsi_host );
++
++ /* tfm: NULL the static local handle just to be sure. */
++ for (j=0; j<2; j++) {
++ if (ox810sata_driver.ap[j] == ap) {
++ p = ap;
++ break;
++ }
++ }
++ if (p) {
++ printk(KERN_DEBUG "tfm host at %p: NULLing ap pointer #%d @%p\n", host_set, j, ap);
++ ox810sata_driver.ap[j] = NULL;
++ } else {
++ printk(KERN_ERR "tfm host at %p: orphan ap pointer %p\n", host_set, ap);
++ }
+ }
+
+ /** @TODO etc. */
More information about the Openembedded-commits
mailing list