Re: [PATCH 03/11] mmc: sdhci-msm: use sdhci_pltfm_init for private allocation

2016-01-05 Thread Jisheng Zhang
On Tue, 5 Jan 2016 20:47:37 +0800 kbuild test robot wrote:

> Hi Jisheng,
> 
> [auto build test WARNING on v4.4-rc8]
> [also build test WARNING on next-20160105]
> [cannot apply to ulf.hansson-mmc/next]
> [if your patch is applied to the wrong git tree, please drop us a note to 
> help improving the system]
> 
> url:
> https://github.com/0day-ci/linux/commits/Jisheng-Zhang/mmc-sdhci-bcm2835-use-sdhci_pltfm_init-for-private-allocation/20160105-190232
> config: arm64-allmodconfig (attached as .config)
> reproduce:
> wget 
> https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross
>  -O ~/bin/make.cross
> chmod +x ~/bin/make.cross
> # save the attached .config to linux build tree
> make.cross ARCH=arm64 
> 
> All warnings (new ones prefixed by >>):
> 
>drivers/mmc/host/sdhci-msm.c: In function 'sdhci_msm_probe':
> >> drivers/mmc/host/sdhci-msm.c:440:32: warning: 'msm_host' is used 
> >> uninitialized in this function [-Wuninitialized]  
>  host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,

OOPS, I'll fix it.

Thanks a lot,
Jisheng


>^
> 
> vim +/msm_host +440 drivers/mmc/host/sdhci-msm.c
> 
>424.set_clock = sdhci_set_clock,
>425.set_bus_width = sdhci_set_bus_width,
>426.set_uhs_signaling = sdhci_set_uhs_signaling,
>427};
>428
>429static int sdhci_msm_probe(struct platform_device *pdev)
>430{
>431struct sdhci_host *host;
>432struct sdhci_pltfm_host *pltfm_host;
>433struct sdhci_msm_host *msm_host;
>434struct resource *core_memres;
>435int ret;
>436u16 host_version, core_minor;
>437u32 core_version, caps;
>438u8 core_major;
>439
>  > 440host = sdhci_pltfm_init(pdev, 
> _host->sdhci_msm_pdata,  
>441sizeof(*msm_host));
>442if (IS_ERR(host))
>443return PTR_ERR(host);
>444
>445pltfm_host = sdhci_priv(host);
>446msm_host = sdhci_pltfm_priv(pltfm_host);
>447msm_host->sdhci_msm_pdata.ops = _msm_ops;
>448msm_host->mmc = host->mmc;
> 
> ---
> 0-DAY kernel test infrastructureOpen Source Technology Center
> https://lists.01.org/pipermail/kbuild-all   Intel Corporation

--
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 03/11] mmc: sdhci-msm: use sdhci_pltfm_init for private allocation

2016-01-05 Thread kbuild test robot
Hi Jisheng,

[auto build test WARNING on v4.4-rc8]
[also build test WARNING on next-20160105]
[cannot apply to ulf.hansson-mmc/next]
[if your patch is applied to the wrong git tree, please drop us a note to help 
improving the system]

url:
https://github.com/0day-ci/linux/commits/Jisheng-Zhang/mmc-sdhci-bcm2835-use-sdhci_pltfm_init-for-private-allocation/20160105-190232
config: arm64-allmodconfig (attached as .config)
reproduce:
wget 
https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross
 -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=arm64 

All warnings (new ones prefixed by >>):

   drivers/mmc/host/sdhci-msm.c: In function 'sdhci_msm_probe':
>> drivers/mmc/host/sdhci-msm.c:440:32: warning: 'msm_host' is used 
>> uninitialized in this function [-Wuninitialized]
 host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,
   ^

vim +/msm_host +440 drivers/mmc/host/sdhci-msm.c

   424  .set_clock = sdhci_set_clock,
   425  .set_bus_width = sdhci_set_bus_width,
   426  .set_uhs_signaling = sdhci_set_uhs_signaling,
   427  };
   428  
   429  static int sdhci_msm_probe(struct platform_device *pdev)
   430  {
   431  struct sdhci_host *host;
   432  struct sdhci_pltfm_host *pltfm_host;
   433  struct sdhci_msm_host *msm_host;
   434  struct resource *core_memres;
   435  int ret;
   436  u16 host_version, core_minor;
   437  u32 core_version, caps;
   438  u8 core_major;
   439  
 > 440  host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,
   441  sizeof(*msm_host));
   442  if (IS_ERR(host))
   443  return PTR_ERR(host);
   444  
   445  pltfm_host = sdhci_priv(host);
   446  msm_host = sdhci_pltfm_priv(pltfm_host);
   447  msm_host->sdhci_msm_pdata.ops = _msm_ops;
   448  msm_host->mmc = host->mmc;

---
0-DAY kernel test infrastructureOpen Source Technology Center
https://lists.01.org/pipermail/kbuild-all   Intel Corporation


.config.gz
Description: Binary data


[PATCH 03/11] mmc: sdhci-msm: use sdhci_pltfm_init for private allocation

2016-01-05 Thread Jisheng Zhang
Commit 0e748234293f ("mmc: sdhci: Add size for caller in init+register")
allows users of sdhci_pltfm to allocate private space in calls to
sdhci_pltfm_init+sdhci_pltfm_register. This patch migrates sdhci-msm
to this allocation.

Signed-off-by: Jisheng Zhang 
---
 drivers/mmc/host/sdhci-msm.c | 13 +
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index 4695bee..0109446 100644
--- a/drivers/mmc/host/sdhci-msm.c
+++ b/drivers/mmc/host/sdhci-msm.c
@@ -437,17 +437,14 @@ static int sdhci_msm_probe(struct platform_device *pdev)
u32 core_version, caps;
u8 core_major;
 
-   msm_host = devm_kzalloc(>dev, sizeof(*msm_host), GFP_KERNEL);
-   if (!msm_host)
-   return -ENOMEM;
-
-   msm_host->sdhci_msm_pdata.ops = _msm_ops;
-   host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata, 0);
+   host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,
+   sizeof(*msm_host));
if (IS_ERR(host))
return PTR_ERR(host);
 
pltfm_host = sdhci_priv(host);
-   pltfm_host->priv = msm_host;
+   msm_host = sdhci_pltfm_priv(pltfm_host);
+   msm_host->sdhci_msm_pdata.ops = _msm_ops;
msm_host->mmc = host->mmc;
msm_host->pdev = pdev;
 
@@ -570,7 +567,7 @@ static int sdhci_msm_remove(struct platform_device *pdev)
 {
struct sdhci_host *host = platform_get_drvdata(pdev);
struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
-   struct sdhci_msm_host *msm_host = pltfm_host->priv;
+   struct sdhci_msm_host *msm_host = sdhci_pltfm_priv(pltfm_host);
int dead = (readl_relaxed(host->ioaddr + SDHCI_INT_STATUS) ==
0x);
 
-- 
2.6.4

--
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 03/11] mmc: sdhci-msm: use sdhci_pltfm_init for private allocation

2016-01-05 Thread Jisheng Zhang
On Tue, 5 Jan 2016 20:47:37 +0800 kbuild test robot wrote:

> Hi Jisheng,
> 
> [auto build test WARNING on v4.4-rc8]
> [also build test WARNING on next-20160105]
> [cannot apply to ulf.hansson-mmc/next]
> [if your patch is applied to the wrong git tree, please drop us a note to 
> help improving the system]
> 
> url:
> https://github.com/0day-ci/linux/commits/Jisheng-Zhang/mmc-sdhci-bcm2835-use-sdhci_pltfm_init-for-private-allocation/20160105-190232
> config: arm64-allmodconfig (attached as .config)
> reproduce:
> wget 
> https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross
>  -O ~/bin/make.cross
> chmod +x ~/bin/make.cross
> # save the attached .config to linux build tree
> make.cross ARCH=arm64 
> 
> All warnings (new ones prefixed by >>):
> 
>drivers/mmc/host/sdhci-msm.c: In function 'sdhci_msm_probe':
> >> drivers/mmc/host/sdhci-msm.c:440:32: warning: 'msm_host' is used 
> >> uninitialized in this function [-Wuninitialized]  
>  host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,

OOPS, I'll fix it.

Thanks a lot,
Jisheng


>^
> 
> vim +/msm_host +440 drivers/mmc/host/sdhci-msm.c
> 
>424.set_clock = sdhci_set_clock,
>425.set_bus_width = sdhci_set_bus_width,
>426.set_uhs_signaling = sdhci_set_uhs_signaling,
>427};
>428
>429static int sdhci_msm_probe(struct platform_device *pdev)
>430{
>431struct sdhci_host *host;
>432struct sdhci_pltfm_host *pltfm_host;
>433struct sdhci_msm_host *msm_host;
>434struct resource *core_memres;
>435int ret;
>436u16 host_version, core_minor;
>437u32 core_version, caps;
>438u8 core_major;
>439
>  > 440host = sdhci_pltfm_init(pdev, 
> _host->sdhci_msm_pdata,  
>441sizeof(*msm_host));
>442if (IS_ERR(host))
>443return PTR_ERR(host);
>444
>445pltfm_host = sdhci_priv(host);
>446msm_host = sdhci_pltfm_priv(pltfm_host);
>447msm_host->sdhci_msm_pdata.ops = _msm_ops;
>448msm_host->mmc = host->mmc;
> 
> ---
> 0-DAY kernel test infrastructureOpen Source Technology Center
> https://lists.01.org/pipermail/kbuild-all   Intel Corporation

--
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 03/11] mmc: sdhci-msm: use sdhci_pltfm_init for private allocation

2016-01-05 Thread Jisheng Zhang
Commit 0e748234293f ("mmc: sdhci: Add size for caller in init+register")
allows users of sdhci_pltfm to allocate private space in calls to
sdhci_pltfm_init+sdhci_pltfm_register. This patch migrates sdhci-msm
to this allocation.

Signed-off-by: Jisheng Zhang 
---
 drivers/mmc/host/sdhci-msm.c | 13 +
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index 4695bee..0109446 100644
--- a/drivers/mmc/host/sdhci-msm.c
+++ b/drivers/mmc/host/sdhci-msm.c
@@ -437,17 +437,14 @@ static int sdhci_msm_probe(struct platform_device *pdev)
u32 core_version, caps;
u8 core_major;
 
-   msm_host = devm_kzalloc(>dev, sizeof(*msm_host), GFP_KERNEL);
-   if (!msm_host)
-   return -ENOMEM;
-
-   msm_host->sdhci_msm_pdata.ops = _msm_ops;
-   host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata, 0);
+   host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,
+   sizeof(*msm_host));
if (IS_ERR(host))
return PTR_ERR(host);
 
pltfm_host = sdhci_priv(host);
-   pltfm_host->priv = msm_host;
+   msm_host = sdhci_pltfm_priv(pltfm_host);
+   msm_host->sdhci_msm_pdata.ops = _msm_ops;
msm_host->mmc = host->mmc;
msm_host->pdev = pdev;
 
@@ -570,7 +567,7 @@ static int sdhci_msm_remove(struct platform_device *pdev)
 {
struct sdhci_host *host = platform_get_drvdata(pdev);
struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
-   struct sdhci_msm_host *msm_host = pltfm_host->priv;
+   struct sdhci_msm_host *msm_host = sdhci_pltfm_priv(pltfm_host);
int dead = (readl_relaxed(host->ioaddr + SDHCI_INT_STATUS) ==
0x);
 
-- 
2.6.4

--
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 03/11] mmc: sdhci-msm: use sdhci_pltfm_init for private allocation

2016-01-05 Thread kbuild test robot
Hi Jisheng,

[auto build test WARNING on v4.4-rc8]
[also build test WARNING on next-20160105]
[cannot apply to ulf.hansson-mmc/next]
[if your patch is applied to the wrong git tree, please drop us a note to help 
improving the system]

url:
https://github.com/0day-ci/linux/commits/Jisheng-Zhang/mmc-sdhci-bcm2835-use-sdhci_pltfm_init-for-private-allocation/20160105-190232
config: arm64-allmodconfig (attached as .config)
reproduce:
wget 
https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross
 -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=arm64 

All warnings (new ones prefixed by >>):

   drivers/mmc/host/sdhci-msm.c: In function 'sdhci_msm_probe':
>> drivers/mmc/host/sdhci-msm.c:440:32: warning: 'msm_host' is used 
>> uninitialized in this function [-Wuninitialized]
 host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,
   ^

vim +/msm_host +440 drivers/mmc/host/sdhci-msm.c

   424  .set_clock = sdhci_set_clock,
   425  .set_bus_width = sdhci_set_bus_width,
   426  .set_uhs_signaling = sdhci_set_uhs_signaling,
   427  };
   428  
   429  static int sdhci_msm_probe(struct platform_device *pdev)
   430  {
   431  struct sdhci_host *host;
   432  struct sdhci_pltfm_host *pltfm_host;
   433  struct sdhci_msm_host *msm_host;
   434  struct resource *core_memres;
   435  int ret;
   436  u16 host_version, core_minor;
   437  u32 core_version, caps;
   438  u8 core_major;
   439  
 > 440  host = sdhci_pltfm_init(pdev, _host->sdhci_msm_pdata,
   441  sizeof(*msm_host));
   442  if (IS_ERR(host))
   443  return PTR_ERR(host);
   444  
   445  pltfm_host = sdhci_priv(host);
   446  msm_host = sdhci_pltfm_priv(pltfm_host);
   447  msm_host->sdhci_msm_pdata.ops = _msm_ops;
   448  msm_host->mmc = host->mmc;

---
0-DAY kernel test infrastructureOpen Source Technology Center
https://lists.01.org/pipermail/kbuild-all   Intel Corporation


.config.gz
Description: Binary data