FreeBSD Bugzilla – Attachment 156209 Details for
Bug 161043
[psm] PS/2 mouse does not work in 9.0-BETA2/-CURRENT [regression]
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
psm_acpi_resource_hack.patch
psm_acpi_resource_hack.patch (text/plain), 2.96 KB, created by
John Baldwin
on 2015-05-01 13:48:55 UTC
(
hide
)
Description:
psm_acpi_resource_hack.patch
Filename:
MIME Type:
Creator:
John Baldwin
Created:
2015-05-01 13:48:55 UTC
Size:
2.96 KB
patch
obsolete
>diff --git sys/conf/options.amd64 sys/conf/options.amd64 >index f1d4b4a..8d5e257 100644 >--- sys/conf/options.amd64 >+++ sys/conf/options.amd64 >@@ -53,6 +53,7 @@ ATKBD_DFLT_KEYMAP opt_atkbd.h > # EOF > # ------------------------------- > HAMMER opt_cpu.h >+DEV_PSM opt_psm.h > PSM_HOOKRESUME opt_psm.h > PSM_RESETAFTERSUSPEND opt_psm.h > PSM_DEBUG opt_psm.h >diff --git sys/conf/options.i386 sys/conf/options.i386 >index 96b6d4d..e6e18aa 100644 >--- sys/conf/options.i386 >+++ sys/conf/options.i386 >@@ -93,6 +93,7 @@ VESA_DEBUG opt_vesa.h > # AGP debugging support > AGP_DEBUG opt_agp.h > >+DEV_PSM opt_psm.h > PSM_DEBUG opt_psm.h > PSM_HOOKRESUME opt_psm.h > PSM_RESETAFTERSUSPEND opt_psm.h >diff --git sys/conf/options.sparc64 sys/conf/options.sparc64 >index 883db16..792aa88 100644 >--- sys/conf/options.sparc64 >+++ sys/conf/options.sparc64 >@@ -19,6 +19,7 @@ OFW_PCI_DEBUG opt_ofw_pci.h > > PMAP_STATS opt_pmap.h > >+DEV_PSM opt_psm.h > PSM_DEBUG opt_psm.h > PSM_HOOKRESUME opt_psm.h > PSM_RESETAFTERSUSPEND opt_psm.h >diff --git sys/dev/acpica/acpi.c sys/dev/acpica/acpi.c >index a597b6d..b87315b 100644 >--- sys/dev/acpica/acpi.c >+++ sys/dev/acpica/acpi.c >@@ -31,6 +31,8 @@ > __FBSDID("$FreeBSD$"); > > #include "opt_acpi.h" >+#include "opt_psm.h" >+ > #include <sys/param.h> > #include <sys/kernel.h> > #include <sys/proc.h> >@@ -65,6 +67,9 @@ __FBSDID("$FreeBSD$"); > > #include <dev/acpica/acpivar.h> > #include <dev/acpica/acpiio.h> >+#ifdef DEV_PSM >+#include <dev/atkbdc/psm.h> >+#endif > > #include <vm/vm_param.h> > >@@ -1258,6 +1263,20 @@ acpi_set_resource(device_t dev, device_t child, int type, int rid, > } > } > >+#ifdef DEV_PSM >+ /* >+ * Ignore I/O port resources for PS/2 mouse devices. Some BIOSes >+ * place the I/O port resources for the AT keyboard controller >+ * under the PS/2 mouse device instead of the keyboard device. >+ * Rather than engaging in crazy gymnastics to move the resources >+ * over to the keyboard controller, just ignore any I/O port >+ * resources and rely on the default hints to provide resources >+ * for the keyboard controller. >+ */ >+ if (type == SYS_RES_IOPORT && ISA_PNP_PROBE(dev, child, psmcpnp_ids) == 0) >+ return (0); >+#endif >+ > /* If the resource is already allocated, fail. */ > if (resource_list_busy(rl, type, rid)) > return (EBUSY); >diff --git sys/dev/atkbdc/psm.c sys/dev/atkbdc/psm.c >index 5703daf..f561dbc 100644 >--- sys/dev/atkbdc/psm.c >+++ sys/dev/atkbdc/psm.c >@@ -4921,7 +4921,7 @@ static driver_t psmcpnp_driver = { > 1, /* no softc */ > }; > >-static struct isa_pnp_id psmcpnp_ids[] = { >+struct isa_pnp_id psmcpnp_ids[] = { > { 0x030fd041, "PS/2 mouse port" }, /* PNP0F03 */ > { 0x0e0fd041, "PS/2 mouse port" }, /* PNP0F0E */ > { 0x120fd041, "PS/2 mouse port" }, /* PNP0F12 */ >diff --git sys/dev/atkbdc/psm.h sys/dev/atkbdc/psm.h >index e687728..ec5ff3c 100644 >--- sys/dev/atkbdc/psm.h >+++ sys/dev/atkbdc/psm.h >@@ -29,4 +29,6 @@ > > #define PSM_DRIVER_NAME "psm" > >+extern struct isa_pnp_id psmcpnp_ids[]; >+ > #endif /* !_DEV_ATKBDC_PSM_H_ */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 161043
: 156209 |
156471
|
156472
|
156473
|
161098
|
186395
|
186396
|
186397