Re: [PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-08 Thread Aaron Sierra
> v2: post-decrement to match existing style
> retitle patch subject
> 
>  drivers/mfd/lpc_ich.c | 3 +++
>  1 file changed, 3 insertions(+)

Acked-by: Aaron Sierra 

You could make Samuel's job easier by sending a new e-mail
with the latest patch and the correct subject in the e-mail's
subject line. Since this patch doesn't really depend on any of
the other four you submitted, a new message/subject like this
seems appropriate to me:

[PATCH v3] mfd: lpc_ich: Fix resource request for [mem 0x]
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-08 Thread Peter Hurley
On Thu, 2012-11-08 at 11:04 -0600, Aaron Sierra wrote:
> > The older southbridges supported by the lpc_ich driver do not
> > provide memory-mapped space of the root complex. The driver
> > correctly avoids computing the iomem address in this case, yet
> > submits a zeroed resource request anyway (via mfd_add_devices()).
> > 
> > Remove the iomem resource from the resource array submitted to the
> > mfd core for the older southbridges.
> > 
> 
> Peter, thanks for catching this.
> 
> > +   } else {
> > +   /* So don't register iomem for TCO ver 1 */
> > +   --lpc_ich_cells[LPC_WDT].num_resources;
> 
> My only complaint is that pre-decrementing num_resources isn't
> necessary and doesn't match the other cases where num_resources is
> decremented (post-decremented), like here:
> 
> if (!base_addr) {
> dev_err(>dev, "I/O space for ACPI uninitialized\n");
> lpc_ich_cells[LPC_GPIO].num_resources--;
> goto gpe0_done;
> }

Sorry, C++ force-of-habit. How's this instead?  (please note, I also
retitled the patch to refer to lpc_ich specifically)

-- >8 --
Subject: [PATCH v2 5/5] mfd: lpc_ich: Fix resource request for [mem 0x]

The older southbridges supported by the lpc_ich driver do not
provide memory-mapped space of the root complex. The driver
correctly avoids computing the iomem address in this case, yet
submits a zeroed resource request anyway (via mfd_add_devices()).

Remove the iomem resource from the resource array submitted to the
mfd core for the older southbridges.

Cc: Aaron Sierra 
Cc: Peter Tyser 
Cc: Samuel Ortiz 
Signed-off-by: Peter Hurley 
---

v2: post-decrement to match existing style
retitle patch subject

 drivers/mfd/lpc_ich.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/mfd/lpc_ich.c b/drivers/mfd/lpc_ich.c
index a22544f..f507c09 100644
--- a/drivers/mfd/lpc_ich.c
+++ b/drivers/mfd/lpc_ich.c
@@ -842,6 +842,9 @@ static int __devinit lpc_ich_init_wdt(struct pci_dev *dev,
res = wdt_mem_res(ICH_RES_MEM_GCS);
res->start = base_addr + ACPIBASE_GCS_OFF;
res->end = base_addr + ACPIBASE_GCS_END;
+   } else {
+   /* So don't register iomem for TCO ver 1 */
+   lpc_ich_cells[LPC_WDT].num_resources--;
}
 
lpc_ich_finalize_cell(_ich_cells[LPC_WDT], id);
-- 
1.8.0




--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-08 Thread Aaron Sierra
> The older southbridges supported by the lpc_ich driver do not
> provide memory-mapped space of the root complex. The driver
> correctly avoids computing the iomem address in this case, yet
> submits a zeroed resource request anyway (via mfd_add_devices()).
> 
> Remove the iomem resource from the resource array submitted to the
> mfd core for the older southbridges.
> 

Peter, thanks for catching this.

> + } else {
> + /* So don't register iomem for TCO ver 1 */
> + --lpc_ich_cells[LPC_WDT].num_resources;

My only complaint is that pre-decrementing num_resources isn't
necessary and doesn't match the other cases where num_resources is
decremented (post-decremented), like here:

if (!base_addr) {
dev_err(>dev, "I/O space for ACPI uninitialized\n");
lpc_ich_cells[LPC_GPIO].num_resources--;
goto gpe0_done;
}

-Aaron
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-08 Thread Aaron Sierra
 The older southbridges supported by the lpc_ich driver do not
 provide memory-mapped space of the root complex. The driver
 correctly avoids computing the iomem address in this case, yet
 submits a zeroed resource request anyway (via mfd_add_devices()).
 
 Remove the iomem resource from the resource array submitted to the
 mfd core for the older southbridges.
 

Peter, thanks for catching this.

 + } else {
 + /* So don't register iomem for TCO ver 1 */
 + --lpc_ich_cells[LPC_WDT].num_resources;

My only complaint is that pre-decrementing num_resources isn't
necessary and doesn't match the other cases where num_resources is
decremented (post-decremented), like here:

if (!base_addr) {
dev_err(dev-dev, I/O space for ACPI uninitialized\n);
lpc_ich_cells[LPC_GPIO].num_resources--;
goto gpe0_done;
}

-Aaron
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-08 Thread Peter Hurley
On Thu, 2012-11-08 at 11:04 -0600, Aaron Sierra wrote:
  The older southbridges supported by the lpc_ich driver do not
  provide memory-mapped space of the root complex. The driver
  correctly avoids computing the iomem address in this case, yet
  submits a zeroed resource request anyway (via mfd_add_devices()).
  
  Remove the iomem resource from the resource array submitted to the
  mfd core for the older southbridges.
  
 
 Peter, thanks for catching this.
 
  +   } else {
  +   /* So don't register iomem for TCO ver 1 */
  +   --lpc_ich_cells[LPC_WDT].num_resources;
 
 My only complaint is that pre-decrementing num_resources isn't
 necessary and doesn't match the other cases where num_resources is
 decremented (post-decremented), like here:
 
 if (!base_addr) {
 dev_err(dev-dev, I/O space for ACPI uninitialized\n);
 lpc_ich_cells[LPC_GPIO].num_resources--;
 goto gpe0_done;
 }

Sorry, C++ force-of-habit. How's this instead?  (please note, I also
retitled the patch to refer to lpc_ich specifically)

-- 8 --
Subject: [PATCH v2 5/5] mfd: lpc_ich: Fix resource request for [mem 0x]

The older southbridges supported by the lpc_ich driver do not
provide memory-mapped space of the root complex. The driver
correctly avoids computing the iomem address in this case, yet
submits a zeroed resource request anyway (via mfd_add_devices()).

Remove the iomem resource from the resource array submitted to the
mfd core for the older southbridges.

Cc: Aaron Sierra asie...@xes-inc.com
Cc: Peter Tyser pty...@xes-inc.com
Cc: Samuel Ortiz sa...@linux.intel.com
Signed-off-by: Peter Hurley pe...@hurleysoftware.com
---

v2: post-decrement to match existing style
retitle patch subject

 drivers/mfd/lpc_ich.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/mfd/lpc_ich.c b/drivers/mfd/lpc_ich.c
index a22544f..f507c09 100644
--- a/drivers/mfd/lpc_ich.c
+++ b/drivers/mfd/lpc_ich.c
@@ -842,6 +842,9 @@ static int __devinit lpc_ich_init_wdt(struct pci_dev *dev,
res = wdt_mem_res(ICH_RES_MEM_GCS);
res-start = base_addr + ACPIBASE_GCS_OFF;
res-end = base_addr + ACPIBASE_GCS_END;
+   } else {
+   /* So don't register iomem for TCO ver 1 */
+   lpc_ich_cells[LPC_WDT].num_resources--;
}
 
lpc_ich_finalize_cell(lpc_ich_cells[LPC_WDT], id);
-- 
1.8.0




--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-08 Thread Aaron Sierra
 v2: post-decrement to match existing style
 retitle patch subject
 
  drivers/mfd/lpc_ich.c | 3 +++
  1 file changed, 3 insertions(+)

Acked-by: Aaron Sierra asie...@xes-inc.com

You could make Samuel's job easier by sending a new e-mail
with the latest patch and the correct subject in the e-mail's
subject line. Since this patch doesn't really depend on any of
the other four you submitted, a new message/subject like this
seems appropriate to me:

[PATCH v3] mfd: lpc_ich: Fix resource request for [mem 0x]
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-07 Thread Peter Hurley
The older southbridges supported by the lpc_ich driver do not
provide memory-mapped space of the root complex. The driver
correctly avoids computing the iomem address in this case, yet
submits a zeroed resource request anyway (via mfd_add_devices()).

Remove the iomem resource from the resource array submitted to the
mfd core for the older southbridges.

Cc: Aaron Sierra 
Cc: Peter Tyser 
Cc: Samuel Ortiz 
Signed-off-by: Peter Hurley 
---
 drivers/mfd/lpc_ich.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/mfd/lpc_ich.c b/drivers/mfd/lpc_ich.c
index a22544f..a46095b 100644
--- a/drivers/mfd/lpc_ich.c
+++ b/drivers/mfd/lpc_ich.c
@@ -842,6 +842,9 @@ static int __devinit lpc_ich_init_wdt(struct pci_dev *dev,
res = wdt_mem_res(ICH_RES_MEM_GCS);
res->start = base_addr + ACPIBASE_GCS_OFF;
res->end = base_addr + ACPIBASE_GCS_END;
+   } else {
+   /* So don't register iomem for TCO ver 1 */
+   --lpc_ich_cells[LPC_WDT].num_resources;
}
 
lpc_ich_finalize_cell(_ich_cells[LPC_WDT], id);
-- 
1.7.12.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 5/5] drivers: mfd: Fix resource request for [mem 0x00000000]

2012-11-07 Thread Peter Hurley
The older southbridges supported by the lpc_ich driver do not
provide memory-mapped space of the root complex. The driver
correctly avoids computing the iomem address in this case, yet
submits a zeroed resource request anyway (via mfd_add_devices()).

Remove the iomem resource from the resource array submitted to the
mfd core for the older southbridges.

Cc: Aaron Sierra asie...@xes-inc.com
Cc: Peter Tyser pty...@xes-inc.com
Cc: Samuel Ortiz sa...@linux.intel.com
Signed-off-by: Peter Hurley pe...@hurleysoftware.com
---
 drivers/mfd/lpc_ich.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/mfd/lpc_ich.c b/drivers/mfd/lpc_ich.c
index a22544f..a46095b 100644
--- a/drivers/mfd/lpc_ich.c
+++ b/drivers/mfd/lpc_ich.c
@@ -842,6 +842,9 @@ static int __devinit lpc_ich_init_wdt(struct pci_dev *dev,
res = wdt_mem_res(ICH_RES_MEM_GCS);
res-start = base_addr + ACPIBASE_GCS_OFF;
res-end = base_addr + ACPIBASE_GCS_END;
+   } else {
+   /* So don't register iomem for TCO ver 1 */
+   --lpc_ich_cells[LPC_WDT].num_resources;
}
 
lpc_ich_finalize_cell(lpc_ich_cells[LPC_WDT], id);
-- 
1.7.12.3

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/