Skip to content

Commit

Permalink
mfd: lpc_ich: Make struct lpc_ich_priv use enum for chipset member
Browse files Browse the repository at this point in the history
We have a specific enum for the supported chipsets.
Make struct lpc_ich_priv use better type for the chipset member.

Signed-off-by: Andy Shevchenko <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Lee Jones <[email protected]>
  • Loading branch information
andy-shev authored and lag-linaro committed Nov 1, 2023
1 parent 8cdbe51 commit b0eb618
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions drivers/mfd/lpc_ich.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,19 +85,6 @@
#define wdt_mem_res(i) wdt_res(ICH_RES_MEM_OFF, i)
#define wdt_res(b, i) (&wdt_ich_res[(b) + (i)])

struct lpc_ich_priv {
int chipset;

int abase; /* ACPI base */
int actrl_pbase; /* ACPI control or PMC base */
int gbase; /* GPIO base */
int gctrl; /* GPIO control */

int abase_save; /* Cached ACPI base value */
int actrl_pbase_save; /* Cached ACPI control or PMC base value */
int gctrl_save; /* Cached GPIO control value */
};

static struct resource wdt_ich_res[] = {
/* ACPI - TCO */
{
Expand Down Expand Up @@ -293,6 +280,19 @@ enum lpc_chipsets {
LPC_COUGARMOUNTAIN,/* Cougar Mountain SoC*/
};

struct lpc_ich_priv {
enum lpc_chipsets chipset;

int abase; /* ACPI base */
int actrl_pbase; /* ACPI control or PMC base */
int gbase; /* GPIO base */
int gctrl; /* GPIO control */

int abase_save; /* Cached ACPI base value */
int actrl_pbase_save; /* Cached ACPI control or PMC base value */
int gctrl_save; /* Cached GPIO control value */
};

static struct lpc_ich_info lpc_chipset_info[] = {
[LPC_ICH] = {
.name = "ICH",
Expand Down

0 comments on commit b0eb618

Please sign in to comment.