diff options
author | Michael Niewöhner <foss@mniewoehner.de> | 2020-12-26 22:20:49 +0100 |
---|---|---|
committer | Michael Niewöhner <foss@mniewoehner.de> | 2020-12-28 21:01:08 +0000 |
commit | 6e016f031faa9c20224bae491aca868d377bce37 (patch) | |
tree | 9ec1bc1e25eeb43db14b243afbff20f71c3b0d3c | |
parent | dbb667ac08f8283eb38861151f971efd46736ab6 (diff) |
device/pnp: add register PNP_IO4
Add the register PNP_IO4, which will be used by IT5570E in CB:48894.
Change-Id: Ic820295247323f546d4c48ed17cfa4eab3dc5e92
Signed-off-by: Michael Niewöhner <foss@mniewoehner.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/48924
Reviewed-by: Felix Singer <felixsinger@posteo.net>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r-- | src/device/pnp_device.c | 2 | ||||
-rw-r--r-- | src/include/device/pnp.h | 51 | ||||
-rw-r--r-- | src/include/device/pnp_def.h | 1 |
3 files changed, 29 insertions, 25 deletions
diff --git a/src/device/pnp_device.c b/src/device/pnp_device.c index afe6948a3a..259d449752 100644 --- a/src/device/pnp_device.c +++ b/src/device/pnp_device.c @@ -249,6 +249,8 @@ static void get_resources(struct device *dev, struct pnp_info *info) pnp_get_ioresource(dev, PNP_IDX_IO2, info->io2); if (info->flags & PNP_IO3) pnp_get_ioresource(dev, PNP_IDX_IO3, info->io3); + if (info->flags & PNP_IO4) + pnp_get_ioresource(dev, PNP_IDX_IO4, info->io4); if (info->flags & PNP_IRQ0) { resource = new_resource(dev, PNP_IDX_IRQ0); diff --git a/src/include/device/pnp.h b/src/include/device/pnp.h index 635876b902..955eac29ac 100644 --- a/src/include/device/pnp.h +++ b/src/include/device/pnp.h @@ -38,31 +38,32 @@ struct pnp_info { #define PNP_SKIP_FUNCTION 0xffff u16 function; /* Must be at least 16 bits (virtual LDNs)! */ unsigned int flags; -#define PNP_IO0 0x000001 -#define PNP_IO1 0x000002 -#define PNP_IO2 0x000004 -#define PNP_IO3 0x000008 -#define PNP_IRQ0 0x000010 -#define PNP_IRQ1 0x000020 -#define PNP_DRQ0 0x000040 -#define PNP_DRQ1 0x000080 -#define PNP_EN 0x000100 -#define PNP_MSC0 0x000200 -#define PNP_MSC1 0x000400 -#define PNP_MSC2 0x000800 -#define PNP_MSC3 0x001000 -#define PNP_MSC4 0x002000 -#define PNP_MSC5 0x004000 -#define PNP_MSC6 0x008000 -#define PNP_MSC7 0x010000 -#define PNP_MSC8 0x020000 -#define PNP_MSC9 0x040000 -#define PNP_MSCA 0x080000 -#define PNP_MSCB 0x100000 -#define PNP_MSCC 0x200000 -#define PNP_MSCD 0x400000 -#define PNP_MSCE 0x800000 - u16 io0, io1, io2, io3; +#define PNP_IO0 0x0000001 +#define PNP_IO1 0x0000002 +#define PNP_IO2 0x0000004 +#define PNP_IO3 0x0000008 +#define PNP_IO4 0x0000010 +#define PNP_IRQ0 0x0000020 +#define PNP_IRQ1 0x0000040 +#define PNP_DRQ0 0x0000080 +#define PNP_DRQ1 0x0000100 +#define PNP_EN 0x0000200 +#define PNP_MSC0 0x0000400 +#define PNP_MSC1 0x0000800 +#define PNP_MSC2 0x0001000 +#define PNP_MSC3 0x0002000 +#define PNP_MSC4 0x0004000 +#define PNP_MSC5 0x0008000 +#define PNP_MSC6 0x0010000 +#define PNP_MSC7 0x0020000 +#define PNP_MSC8 0x0040000 +#define PNP_MSC9 0x0080000 +#define PNP_MSCA 0x0100000 +#define PNP_MSCB 0x0200000 +#define PNP_MSCC 0x0400000 +#define PNP_MSCD 0x0800000 +#define PNP_MSCE 0x1000000 + u16 io0, io1, io2, io3, io4; }; struct resource *pnp_get_resource(struct device *dev, unsigned int index); void pnp_enable_devices(struct device *dev, struct device_operations *ops, diff --git a/src/include/device/pnp_def.h b/src/include/device/pnp_def.h index 7701d842f2..712357bb7c 100644 --- a/src/include/device/pnp_def.h +++ b/src/include/device/pnp_def.h @@ -6,6 +6,7 @@ #define PNP_IDX_IO1 0x62 #define PNP_IDX_IO2 0x64 #define PNP_IDX_IO3 0x66 +#define PNP_IDX_IO4 0x68 #define PNP_IDX_IRQ0 0x70 #define PNP_IDX_IRQ1 0x72 #define PNP_IDX_DRQ0 0x74 |