Re: [PATCH 08/33] drivers/i2c/busses: don't check resource with devm_ioremap_resource
On 05/16/13 20:15, Wolfram Sang wrote: devm_ioremap_resource does sanity checks on the given resource. No need to duplicate this in the driver. Signed-off-by: Wolfram Sangw...@the-dreams.de For i2c-s3c2410: Acked-by: Kukjin Kim kgene@samsung.com Thanks. - Kukjin --- drivers/i2c/busses/i2c-s3c2410.c |5 - drivers/i2c/busses/i2c-sirf.c|6 -- drivers/i2c/busses/i2c-tegra.c |5 - 3 files changed, 16 deletions(-) diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c index 6e8ee92..cab1c91 100644 --- a/drivers/i2c/busses/i2c-s3c2410.c +++ b/drivers/i2c/busses/i2c-s3c2410.c @@ -1082,11 +1082,6 @@ static int s3c24xx_i2c_probe(struct platform_device *pdev) /* map the registers */ res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (res == NULL) { - dev_err(pdev-dev, cannot find IO resource\n); - return -ENOENT; - } - i2c-regs = devm_ioremap_resource(pdev-dev, res); if (IS_ERR(i2c-regs)) diff --git a/drivers/i2c/busses/i2c-sirf.c b/drivers/i2c/busses/i2c-sirf.c index 5a7ad24..a63c7d5 100644 --- a/drivers/i2c/busses/i2c-sirf.c +++ b/drivers/i2c/busses/i2c-sirf.c @@ -303,12 +303,6 @@ static int i2c_sirfsoc_probe(struct platform_device *pdev) adap-class = I2C_CLASS_HWMON; mem_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (mem_res == NULL) { - dev_err(pdev-dev, Unable to get MEM resource\n); - err = -EINVAL; - goto out; - } - siic-base = devm_ioremap_resource(pdev-dev, mem_res); if (IS_ERR(siic-base)) { err = PTR_ERR(siic-base); diff --git a/drivers/i2c/busses/i2c-tegra.c b/drivers/i2c/busses/i2c-tegra.c index b60ff90..9aa1b60 100644 --- a/drivers/i2c/busses/i2c-tegra.c +++ b/drivers/i2c/busses/i2c-tegra.c @@ -714,11 +714,6 @@ static int tegra_i2c_probe(struct platform_device *pdev) int ret = 0; res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (!res) { - dev_err(pdev-dev, no mem resource\n); - return -EINVAL; - } - base = devm_ioremap_resource(pdev-dev, res); if (IS_ERR(base)) return PTR_ERR(base); -- To unsubscribe from this list: send the line unsubscribe linux-i2c in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH] MIPS: OCTEON: Rename Kconfig CAVIUM_OCTEON_REFERENCE_BOARD to CAVIUM_OCTEON_SOC
From: David Daney david.da...@cavium.com CAVIUM_OCTEON_SOC most place we used to use CPU_CAVIUM_OCTEON. This allows us to CPU_CAVIUM_OCTEON in places where we have no OCTEON SOC. Remove CAVIUM_OCTEON_SIMULATOR as it doesn't really do anything, we can get the same configuration with CAVIUM_OCTEON_SOC. Signed-off-by: David Daney david.da...@cavium.com Cc: linux-...@vger.kernel.org Cc: linux-e...@vger.kernel.org Cc: linux-i2c@vger.kernel.org Cc: net...@vger.kernel.org Cc: spi-devel-gene...@lists.sourceforge.net Cc: de...@driverdev.osuosl.org Cc: linux-...@vger.kernel.org --- It may make sense to merge this before 3.10 as it touches a ton of Kconfigs that are more likely to experiance merge problems in a full merge window. Also it is only Kconfigery and no 'real' code, so there are fewer chances of really screwing things up. arch/mips/Kconfig | 19 ++- arch/mips/cavium-octeon/Kconfig | 6 +- arch/mips/cavium-octeon/Platform | 8 arch/mips/configs/cavium_octeon_defconfig | 2 +- arch/mips/pci/Makefile| 4 ++-- drivers/ata/Kconfig | 2 +- drivers/char/hw_random/Kconfig| 2 +- drivers/edac/Kconfig | 6 +++--- drivers/i2c/busses/Kconfig| 2 +- drivers/net/ethernet/octeon/Kconfig | 2 +- drivers/net/phy/Kconfig | 2 +- drivers/spi/Kconfig | 2 +- drivers/staging/octeon/Kconfig| 2 +- drivers/usb/host/Kconfig | 4 ++-- 14 files changed, 26 insertions(+), 37 deletions(-) diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index 2ae8e1d..baa3fa0 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -737,23 +737,8 @@ config WR_PPMC This enables support for the Wind River MIPS32 4KC PPMC evaluation board, which is based on GT64120 bridge chip. -config CAVIUM_OCTEON_SIMULATOR - bool Cavium Networks Octeon Simulator - select CEVT_R4K - select 64BIT_PHYS_ADDR - select DMA_COHERENT - select SYS_SUPPORTS_64BIT_KERNEL - select SYS_SUPPORTS_BIG_ENDIAN - select SYS_SUPPORTS_HOTPLUG_CPU - select SYS_HAS_CPU_CAVIUM_OCTEON - select HOLES_IN_ZONE - help - The Octeon simulator is software performance model of the Cavium - Octeon Processor. It supports simulating Octeon processors on x86 - hardware. - -config CAVIUM_OCTEON_REFERENCE_BOARD - bool Cavium Networks Octeon reference board +config CAVIUM_OCTEON_SOC + bool Cavium Networks Octeon SoC based boards select CEVT_R4K select 64BIT_PHYS_ADDR select DMA_COHERENT diff --git a/arch/mips/cavium-octeon/Kconfig b/arch/mips/cavium-octeon/Kconfig index 75a6df7..a12444a 100644 --- a/arch/mips/cavium-octeon/Kconfig +++ b/arch/mips/cavium-octeon/Kconfig @@ -10,6 +10,10 @@ config CAVIUM_CN63XXP1 non-CN63XXP1 hardware, so it is recommended to select n unless it is known the workarounds are needed. +endif # CPU_CAVIUM_OCTEON + +if CAVIUM_OCTEON_SOC + config CAVIUM_OCTEON_2ND_KERNEL bool Build the kernel to be used as a 2nd kernel on the same chip default n @@ -103,4 +107,4 @@ config OCTEON_ILM To compile this driver as a module, choose M here. The module will be called octeon-ilm -endif # CPU_CAVIUM_OCTEON +endif # CAVIUM_OCTEON_SOC diff --git a/arch/mips/cavium-octeon/Platform b/arch/mips/cavium-octeon/Platform index 1e43ccf..8a301cb 100644 --- a/arch/mips/cavium-octeon/Platform +++ b/arch/mips/cavium-octeon/Platform @@ -1,11 +1,11 @@ # # Cavium Octeon # -platform-$(CONFIG_CPU_CAVIUM_OCTEON) += cavium-octeon/ -cflags-$(CONFIG_CPU_CAVIUM_OCTEON) += \ +platform-$(CONFIG_CAVIUM_OCTEON_SOC) += cavium-octeon/ +cflags-$(CONFIG_CAVIUM_OCTEON_SOC) += \ -I$(srctree)/arch/mips/include/asm/mach-cavium-octeon ifdef CONFIG_CAVIUM_OCTEON_2ND_KERNEL -load-$(CONFIG_CPU_CAVIUM_OCTEON) += 0x8410 +load-$(CONFIG_CAVIUM_OCTEON_SOC) += 0x8410 else -load-$(CONFIG_CPU_CAVIUM_OCTEON) += 0x8110 +load-$(CONFIG_CAVIUM_OCTEON_SOC) += 0x8110 endif diff --git a/arch/mips/configs/cavium_octeon_defconfig b/arch/mips/configs/cavium_octeon_defconfig index 014ba4b..1888e5f 100644 --- a/arch/mips/configs/cavium_octeon_defconfig +++ b/arch/mips/configs/cavium_octeon_defconfig @@ -1,4 +1,4 @@ -CONFIG_CAVIUM_OCTEON_REFERENCE_BOARD=y +CONFIG_CAVIUM_OCTEON_SOC=y CONFIG_CAVIUM_CN63XXP1=y CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE=2 CONFIG_SPARSEMEM_MANUAL=y diff --git a/arch/mips/pci/Makefile b/arch/mips/pci/Makefile index 2cb1d31..fa3bcd2 100644 --- a/arch/mips/pci/Makefile +++ b/arch/mips/pci/Makefile @@ -54,10 +54,10 @@ obj-$(CONFIG_VICTOR_MPC30X) += fixup-mpc30x.o obj-$(CONFIG_ZAO_CAPCELLA) += fixup-capcella.o
Re: [PATCH] MIPS: OCTEON: Rename Kconfig CAVIUM_OCTEON_REFERENCE_BOARD to CAVIUM_OCTEON_SOC
On Mon, May 20, 2013 at 03:19:38PM -0700, David Daney wrote: From: David Daney david.da...@cavium.com CAVIUM_OCTEON_SOC most place we used to use CPU_CAVIUM_OCTEON. This allows us to CPU_CAVIUM_OCTEON in places where we have no OCTEON SOC. Remove CAVIUM_OCTEON_SIMULATOR as it doesn't really do anything, we can get the same configuration with CAVIUM_OCTEON_SOC. Signed-off-by: David Daney david.da...@cavium.com Cc: linux-...@vger.kernel.org Cc: linux-e...@vger.kernel.org Cc: linux-i2c@vger.kernel.org Cc: net...@vger.kernel.org Cc: spi-devel-gene...@lists.sourceforge.net Cc: de...@driverdev.osuosl.org Cc: linux-...@vger.kernel.org --- Acked-by: Greg Kroah-Hartman gre...@linuxfoundation.org -- To unsubscribe from this list: send the line unsubscribe linux-i2c in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH] i2c: i2c-designware: Fix compilation warning
Fix the following compilation warning when CONFIG_PM_RUNTIME is not enabled: drivers/i2c/busses/i2c-designware-pcidrv.c:188: warning: 'i2c_dw_pci_runtime_idle' defined but not used Signed-off-by: EunBong Song eunb.s...@samsung.com --- drivers/i2c/busses/i2c-designware-pcidrv.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/i2c/busses/i2c-designware-pcidrv.c b/drivers/i2c/busses/i2c-designware-pcidrv.c index f6ed06c..2b5d3a6 100644 --- a/drivers/i2c/busses/i2c-designware-pcidrv.c +++ b/drivers/i2c/busses/i2c-designware-pcidrv.c @@ -185,6 +185,7 @@ static int i2c_dw_pci_resume(struct device *dev) return 0; } +#ifdef CONFIG_PM_RUNTIME static int i2c_dw_pci_runtime_idle(struct device *dev) { int err = pm_schedule_suspend(dev, 500); @@ -194,6 +195,7 @@ static int i2c_dw_pci_runtime_idle(struct device *dev) return 0; return -EBUSY; } +#endif static const struct dev_pm_ops i2c_dw_pm_ops = { .resume = i2c_dw_pci_resume, -- 1.7.10.4 N떑꿩�r툤y鉉싕b쾊Ф푤v�^�)頻{.n�+돴쪐{콏g왲^n뇊⊆쫧�곷h솳鈺���췍쳺�h�(��쉸듶줷얎�m��곴�z받뻿筬f"톒쉱�~늤