Hi!
This patch is "UBUNTU Way" Solution described in
If I understand correctly, you are saying there are two patches that
deal with deciding whether ata_piix or hv_storvsc handles a device and
making sure CD-ROMs are still usable:
http://thread.gmane.org/gmane.linux.ide/51712
http://thread.gmane.org/gmane.linux.kernel/1186996/
that the former of the two works a little better,
that Mathieu was using the former,
and that upstream has not committed to one yet. Ok.
{
{ This is _old_ variant "OpenSUSE Way"
http://thread.gmane.org/gmane.linux.kernel/1186996/
1 Sep 17:43 Olaf Hering [PATCH RFC] ata_piix: ignore disks in a hyper-v
guest
}
New variant see in
http://marc.info/?l=linux-kernel&m=133302969709312&w=2
Or
http://vvm.blog.tut.by/2012/03/29/linux-on-hyper-v-use-hv_storvsc-instead-of-ata_piix-to-handle-the-ide-disks-devices-but-not-for-the-dvd-rom-cd-rom-device-handling/
Or
http://kernel.opensuse.org/cgit/kernel/commit/?id=aeff3a8fcde6df6e7f26618c5e3bc716a6aa9e85
http://kernel.opensuse.org/cgit/kernel/tree/drivers/ata/ata_piix.c?id=aeff3a8fcde6df6e7f26618c5e3bc716a6aa9e85
[
http://kernel.opensuse.org/cgit/kernel/plain/drivers/ata/ata_piix.c?id=aeff3a8fcde6df6e7f26618c5e3bc716a6aa9e85
]
==
}
{
{
matsimons-hv-kernel
linux-3.2-hyperv
https://gitorious.org/~matsimon/linux-gymkl/matsimons-hv-kernel/commits/linux-3.2-hyperv
on "2012-03-29 07-33"
use _first_/ _old_ variant "UBUNTU Way" ata_piix.c
}
But after
https://launchpad.net/ubuntu/+source/linux/3.2.0-18.29
[
http://launchpadlibrarian.net/96134755/linux_3.2.0-18.28_3.2.0-18.29.diff.gz
]
===
...
--- linux-3.2.0/debian/changelog
+++ linux-3.2.0/debian/changelog
@@ -1,3 +1,39 @@
+linux (3.2.0-18.29) precise; urgency=low
+
+ [ Andy Whitcroft ]
+
+ * [Config] restore build-% shortcut
+ * SAUCE: ata_piix: defer disks to the Hyper-V drivers by default
+ - LP: #929545, #942316
+
...
===
===
...
--- linux-3.2.0/drivers/ata/ata_piix.c
+++ linux-3.2.0/drivers/ata/ata_piix.c
@@ -191,6 +191,29 @@
static unsigned int in_module_init = 1;
+static int prefer_ms_hyperv = 1;
+
+unsigned int ata_piix_read_id(struct ata_device *dev,
+ struct ata_taskfile *tf, u16 *id)
+{
+ int ret = ata_do_dev_read_id(dev, tf, id);
+
+#ifdef CONFIG_X86
+ /* XXX: note that the device id is in little-endian order, the caller
+ * will shift it to host order, but we are working with little-endian.
+ * As this is _only_ used on x86 we can actually directly access it
+ * as host is also little-endian.
+ */
+ if (!ret && prefer_ms_hyperv && x86_hyper == &x86_hyper_ms_hyperv &&
+ ata_id_is_ata(id)) {
+ ata_dev_printk(dev, KERN_WARNING, "ATA disk ignored deferring to Hyper-V paravirt
driver\n");
+
+ return AC_ERR_DEV|AC_ERR_NODEV_HINT;
+ }
+#endif
+ return ret;
+}
+
static const struct pci_device_id piix_pci_tbl[] = {
/* Intel PIIX3 for the 430HX etc */
{ 0x8086, 0x7010, PCI_ANY_ID, PCI_ANY_ID, 0, 0, piix_pata_mwdma },
@@ -362,6 +385,7 @@
.set_piomode = piix_set_piomode,
.set_dmamode = piix_set_dmamode,
.prereset = piix_pata_prereset,
+ .read_id = ata_piix_read_id,
};
static struct ata_port_operations piix_vmw_ops = {
@@ -1677,21 +1701,9 @@
ata_pci_remove_one(pdev);
}
-static int prefer_ms_hyperv = 1;
-
static int __init piix_init(void)
{
int rc;
-#ifdef CONFIG_X86
- /*
- * If we are on the Microsoft Hyper-V platform deferr to its block
- * drivers.
- */
- if (prefer_ms_hyperv && x86_hyper == &x86_hyper_ms_hyperv) {
- pr_info("ata_piix: deferring to Hyper-V hypervisor");
- return -ENODEV;
- }
-#endif
DPRINTK("pci_register_driver\n");
rc = pci_register_driver(&piix_pci_driver);
diff -u linux-3.2.0/fs/binfmt_elf.c linux-3.2.0/fs/binfmt_elf.c
...
===
Ubuntu use this:
{
This patch is "UBUNTU Way"
http://thread.gmane.org/gmane.linux.ide/51712
29 Mar 19:28 Andy Whitcroft [PATCH 1/1] ata_piix: defer disks to the
Hyper-V paravirtualised drive
30 Mar 11:14 Victor Miasnikov [PATCH 1/1] ata_piix: defer disks to the
Hyper-V paravirtualised drive
}
}
IMHO, need use
==
29 Mar 19:28 Andy Whitcroft [PATCH 1/1] ata_piix: defer disks to the Hyper-V
paravirtualised drive
==
may be, combine with some ideas from _latest_ "OpenSUSE Way"
Thanks,
No problem :-)
Best regards, Victor Miasnikov
Blog: http://vvm.blog.tut.by/
P.S. About Ubuntu v12.04 on Hyper-V:
http://www.thomasmaurer.ch/2012/03/install-ubuntu-12-04-on-hyper-v/
==
on March 26, 2012 by Thomas Maurer
. . . work fine
==
http://www.yusufozturk.info/linux-server/future-of-linux-support-ubuntu-12-on-hyper-v-v3.html
==
Future of Linux Support: Ubuntu 12 on Hyper-V v3
26/03/2012 04:19
==
--
To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/4b9b2abdb8fc42dd8dbfc223ddf5a...@local.st.by