From: Jiang Liu <jiang.liu@linux.intel.com>
To: James Bottomley <James.Bottomley@HansenPartnership.com>,
Thomas Gleixner <tglx@linutronix.de>,
Bjorn Helgaas <bhelgaas@google.com>,
Arthur Marsh <arthur.marsh@internode.on.net>,
Hannes Reinecke <hare@suse.de>,
Ballabio@vger.kernel.org, Dario <dario.ballabio@emc.com>,
Christoph Hellwig <hch@infradead.org>
Cc: Jiang Liu <jiang.liu@linux.intel.com>,
linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org,
linux-scsi@vger.kernel.org, x86@kernel.org
Subject: [Bugfix v4 2/2] eata: Ask for help to reset eata controllers for kexec
Date: Thu, 8 Oct 2015 10:51:15 +0800 [thread overview]
Message-ID: <1444272675-14631-2-git-send-email-jiang.liu@linux.intel.com> (raw)
In-Reply-To: <1444272675-14631-1-git-send-email-jiang.liu@linux.intel.com>
Arthur Marsh <arthur.marsh@internode.on.net> reported that with the first
patch applied, he still encountered troubles when doing kexec with eata
devices. Quote Arthur's report:
To clarify, if the eata driver gets loaded once and stays loaded, at a
kexec reboot attempt the "Synchronising SCSI cache" message is missing
for the SCSI disk attached to the controller using the eata driver and
eventually other error messages appear as seen in screen images that
I have previously posted at
http://www.users.on.net/~arthur.marsh/20150915547.jpg.
If the eata driver is loaded, unloaded via modprobe -r, then reloaded,
a kexec reboot shows 2 "Synchronising SCSI cache" messages for the SCSI
disk attached to the controller using the eata driver and the kexec
reboot is successful.
For more details, please refer to thread at:
http://www.gossamer-threads.com/lists/linux/kernel/2251833
https://lkml.org/lkml/2015/9/6/165
First I thought we could solve this issue by implementing a shutdown
callback to reset eata controllers when rebooting, but it turns out
that this patch doesn't really help. And due to limited knowledge about
eata controllers and lack of hardware for tests, helps from eata experts
are really welcomed!
Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
---
drivers/scsi/eata.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/scsi/eata.c b/drivers/scsi/eata.c
index 7315f8adcf65..b83abe283744 100644
--- a/drivers/scsi/eata.c
+++ b/drivers/scsi/eata.c
@@ -1519,6 +1519,11 @@ static void eata2x_pci_remove(struct pci_dev *pdev)
pci_disable_device(pdev);
}
+static void eata2x_pci_shutdown(struct pci_dev *pdev)
+{
+ port_remove(&pdev->dev);
+}
+
static struct pci_device_id eata2x_tbl[] = {
{ PCI_DEVICE_CLASS(PCI_CLASS_STORAGE_SCSI << 8, PCI_ANY_ID) },
{ },
@@ -1530,6 +1535,7 @@ static struct pci_driver eata2x_pci_driver = {
.id_table = eata2x_tbl,
.probe = eata2x_pci_probe,
.remove = eata2x_pci_remove,
+ .shutdown = eata2x_pci_shutdown,
};
static int eata2x_register_pci_driver(void)
@@ -1571,8 +1577,14 @@ static int __exit eata2x_platform_remove(struct platform_device *pdev)
return 0;
}
+static void eata2x_platform_shutdown(struct platform_device *pdev)
+{
+ port_remove(&pdev->dev);
+}
+
static struct platform_driver eata2x_platform_driver = {
.remove = __exit_p(eata2x_platform_remove),
+ .shutdown = eata2x_platform_shutdown,
.driver = {
.name = "eata_plat",
.owner = THIS_MODULE,
--
1.7.10.4
next prev parent reply other threads:[~2015-10-08 2:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-08 2:51 [Bugfix v4 1/2] eata: Convert eata driver as normal PCI and platform device drivers Jiang Liu
2015-10-08 2:51 ` Jiang Liu [this message]
2015-10-08 3:10 ` Jiang Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1444272675-14631-2-git-send-email-jiang.liu@linux.intel.com \
--to=jiang.liu@linux.intel.com \
--cc=Ballabio@vger.kernel.org \
--cc=James.Bottomley@HansenPartnership.com \
--cc=arthur.marsh@internode.on.net \
--cc=bhelgaas@google.com \
--cc=dario.ballabio@emc.com \
--cc=hare@suse.de \
--cc=hch@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).