mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v5 00/12] rework arch/x86/platform/[mrst => intel-mid]
@ 2013-10-16  4:11 David Cohen
  2013-10-16  4:11 ` [PATCH v5 01/12] mrst: Fixed printk/pr_* related issues David Cohen
                   ` (11 more replies)
  0 siblings, 12 replies; 29+ messages in thread
From: David Cohen @ 2013-10-16  4:11 UTC (permalink / raw)
  To: x86, hpa, mingo, tglx
  Cc: linux-kernel, sathyanarayanan.kuppuswamy, David Cohen

This patch set does initial rework from arch/x86/platform/mrst to
arch/x86/platform/intel-mid.
These changes are necessary to update the obsolete Intel Atom Moorestown code
to support the newer Atom processors of this family (called 'intel-mid'). 

David Cohen (3):
  intel-mid: sfi: allow struct devs_id.get_platform_data to be NULL
  x86: intel-mid: add section for sfi device table
  intel_mid: Moved board related code to a new file

Kuppuswamy Sathyanarayanan (9):
  mrst: Fixed printk/pr_* related issues
  mrst: Fixed indentation issues
  mrst: Fixed checkpatch warnings
  intel_mid: Renamed *mrst* to *intel_mid*
  intel_mid: Renamed *mrst* to *intel_mid*
  intel_mid: Refactored sfi_parse_devs() function
  intel_mid: Added custom device_handler support
  intel_mid: Added custom handler for ipc devices
  intel_mid: Moved SFI related code to sfi.c

 Documentation/kernel-parameters.txt                |    6 +-
 arch/x86/include/asm/intel-mid.h                   |  113 +++
 .../include/asm/{mrst-vrtc.h => intel_mid_vrtc.h}  |    4 +-
 arch/x86/include/asm/mrst.h                        |   81 --
 arch/x86/include/asm/setup.h                       |    4 +-
 arch/x86/include/uapi/asm/bootparam.h              |    2 +-
 arch/x86/kernel/apb_timer.c                        |   10 +-
 arch/x86/kernel/early_printk.c                     |    2 +-
 arch/x86/kernel/head32.c                           |    4 +-
 arch/x86/kernel/rtc.c                              |    4 +-
 arch/x86/kernel/vmlinux.lds.S                      |    9 +
 arch/x86/pci/Makefile                              |    2 +-
 arch/x86/pci/{mrst.c => intel_mid_pci.c}           |   14 +-
 arch/x86/platform/Makefile                         |    2 +-
 arch/x86/platform/intel-mid/Makefile               |    8 +
 arch/x86/platform/intel-mid/device_libs/Makefile   |   22 +
 .../intel-mid/device_libs/platform_emc1403.c       |   41 +
 .../intel-mid/device_libs/platform_gpio_keys.c     |   83 ++
 .../platform/intel-mid/device_libs/platform_ipc.c  |   68 ++
 .../platform/intel-mid/device_libs/platform_ipc.h  |   17 +
 .../intel-mid/device_libs/platform_lis331.c        |   39 +
 .../intel-mid/device_libs/platform_max3111.c       |   35 +
 .../intel-mid/device_libs/platform_max7315.c       |   79 ++
 .../intel-mid/device_libs/platform_mpu3050.c       |   36 +
 .../platform/intel-mid/device_libs/platform_msic.c |   87 ++
 .../platform/intel-mid/device_libs/platform_msic.h |   19 +
 .../intel-mid/device_libs/platform_msic_audio.c    |   47 +
 .../intel-mid/device_libs/platform_msic_battery.c  |   37 +
 .../intel-mid/device_libs/platform_msic_gpio.c     |   48 +
 .../intel-mid/device_libs/platform_msic_ocd.c      |   49 +
 .../device_libs/platform_msic_power_btn.c          |   36 +
 .../intel-mid/device_libs/platform_msic_thermal.c  |   37 +
 .../intel-mid/device_libs/platform_pmic_gpio.c     |   54 +
 .../intel-mid/device_libs/platform_tc35876x.c      |   36 +
 .../intel-mid/device_libs/platform_tca6416.c       |   57 ++
 .../early_printk_intel_mid.c}                      |   11 +-
 arch/x86/platform/intel-mid/intel-mid.c            |  213 ++++
 .../{mrst/vrtc.c => intel-mid/intel_mid_vrtc.c}    |   19 +-
 arch/x86/platform/intel-mid/sfi.c                  |  487 +++++++++
 arch/x86/platform/mrst/Makefile                    |    3 -
 arch/x86/platform/mrst/mrst.c                      | 1052 --------------------
 drivers/gpu/drm/gma500/mdfld_dsi_output.h          |    2 +-
 drivers/gpu/drm/gma500/oaktrail_device.c           |    2 +-
 drivers/gpu/drm/gma500/oaktrail_lvds.c             |    2 +-
 drivers/platform/x86/intel_scu_ipc.c               |    4 +-
 drivers/rtc/rtc-mrst.c                             |    4 +-
 drivers/watchdog/intel_scu_watchdog.c              |    4 +-
 47 files changed, 1808 insertions(+), 1187 deletions(-)
 create mode 100644 arch/x86/include/asm/intel-mid.h
 rename arch/x86/include/asm/{mrst-vrtc.h => intel_mid_vrtc.h} (81%)
 delete mode 100644 arch/x86/include/asm/mrst.h
 rename arch/x86/pci/{mrst.c => intel_mid_pci.c} (96%)
 create mode 100644 arch/x86/platform/intel-mid/Makefile
 create mode 100644 arch/x86/platform/intel-mid/device_libs/Makefile
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_emc1403.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_gpio_keys.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_ipc.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_ipc.h
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_lis331.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_max3111.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_max7315.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_mpu3050.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic.h
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic_audio.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic_battery.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic_gpio.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic_ocd.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic_power_btn.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_msic_thermal.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_pmic_gpio.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_tc35876x.c
 create mode 100644 arch/x86/platform/intel-mid/device_libs/platform_tca6416.c
 rename arch/x86/platform/{mrst/early_printk_mrst.c => intel-mid/early_printk_intel_mid.c} (97%)
 create mode 100644 arch/x86/platform/intel-mid/intel-mid.c
 rename arch/x86/platform/{mrst/vrtc.c => intel-mid/intel_mid_vrtc.c} (90%)
 create mode 100644 arch/x86/platform/intel-mid/sfi.c
 delete mode 100644 arch/x86/platform/mrst/Makefile
 delete mode 100644 arch/x86/platform/mrst/mrst.c

-- 
1.8.4.rc3


^ permalink raw reply	[flat|nested] 29+ messages in thread
* [PATCH v10 10/12] intel-mid: sfi: allow struct devs_id.get_platform_data to be NULL
@ 2013-10-17 22:35 David Cohen
  2013-10-18  0:34 ` [tip:x86/intel-mid] intel-mid: sfi: Allow " tip-bot for David Cohen
  0 siblings, 1 reply; 29+ messages in thread
From: David Cohen @ 2013-10-17 22:35 UTC (permalink / raw)
  To: x86, hpa, mingo, tglx
  Cc: linux-kernel, sathyanarayanan.kuppuswamy, David Cohen

Intel mid sfi code doesn't need struct devs_id.get_platform_data != NULL.
If the callback is not set, just assume there is no platform_data.

Signed-off-by: David Cohen <david.a.cohen@linux.intel.com>
Cc: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
---
 arch/x86/platform/intel-mid/sfi.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/arch/x86/platform/intel-mid/sfi.c b/arch/x86/platform/intel-mid/sfi.c
index 2f8196d..3f1c171 100644
--- a/arch/x86/platform/intel-mid/sfi.c
+++ b/arch/x86/platform/intel-mid/sfi.c
@@ -70,6 +70,9 @@ struct blocking_notifier_head intel_scu_notifier =
 			BLOCKING_NOTIFIER_INIT(intel_scu_notifier);
 EXPORT_SYMBOL_GPL(intel_scu_notifier);
 
+#define intel_mid_sfi_get_pdata(dev, priv)	\
+	((dev)->get_platform_data ? (dev)->get_platform_data(priv) : NULL)
+
 /* parse all the mtimer info to a static mtimer array */
 int __init sfi_parse_mtmr(struct sfi_table_header *table)
 {
@@ -334,7 +337,7 @@ static void __init sfi_handle_ipc_dev(struct sfi_device_table_entry *pentry,
 
 	pr_debug("IPC bus, name = %16.16s, irq = 0x%2x\n",
 		pentry->name, pentry->irq);
-	pdata = dev->get_platform_data(pentry);
+	pdata = intel_mid_sfi_get_pdata(dev, pentry);
 
 	pdev = platform_device_alloc(pentry->name, 0);
 	if (pdev == NULL) {
@@ -367,7 +370,7 @@ static void __init sfi_handle_spi_dev(struct sfi_device_table_entry *pentry,
 		spi_info.max_speed_hz,
 		spi_info.chip_select);
 
-	pdata = dev->get_platform_data(&spi_info);
+	pdata = intel_mid_sfi_get_pdata(dev, &spi_info);
 
 	spi_info.platform_data = pdata;
 	if (dev->delay)
@@ -391,7 +394,7 @@ static void __init sfi_handle_i2c_dev(struct sfi_device_table_entry *pentry,
 		i2c_info.type,
 		i2c_info.irq,
 		i2c_info.addr);
-	pdata = dev->get_platform_data(&i2c_info);
+	pdata = intel_mid_sfi_get_pdata(dev, &i2c_info);
 	i2c_info.platform_data = pdata;
 
 	if (dev->delay)
@@ -450,7 +453,7 @@ static int __init sfi_parse_devs(struct sfi_table_header *table)
 
 		dev = get_device_id(pentry->type, pentry->name);
 
-		if ((dev == NULL) || (dev->get_platform_data == NULL))
+		if (!dev)
 			continue;
 
 		if (dev->device_handler) {
-- 
1.8.4.rc3


^ permalink raw reply	[flat|nested] 29+ messages in thread

end of thread, other threads:[~2013-10-18  0:35 UTC | newest]

Thread overview: 29+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-16  4:11 [PATCH v5 00/12] rework arch/x86/platform/[mrst => intel-mid] David Cohen
2013-10-16  4:11 ` [PATCH v5 01/12] mrst: Fixed printk/pr_* related issues David Cohen
2013-10-17 18:18   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 02/12] mrst: Fixed indentation issues David Cohen
2013-10-17 18:18   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 03/12] mrst: Fixed checkpatch warnings David Cohen
2013-10-17 18:18   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 04/12] intel_mid: Renamed *mrst* to *intel_mid* David Cohen
2013-10-17 18:18   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 05/12] " David Cohen
2013-10-17 18:19   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 06/12] intel_mid: Refactored sfi_parse_devs() function David Cohen
2013-10-17 18:19   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 07/12] intel_mid: Added custom device_handler support David Cohen
2013-10-17 18:19   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 08/12] intel_mid: Added custom handler for ipc devices David Cohen
2013-10-17 18:19   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 09/12] intel_mid: Moved SFI related code to sfi.c David Cohen
2013-10-17 18:19   ` [tip:x86/intel-mid] " tip-bot for Kuppuswamy Sathyanarayanan
2013-10-16  4:11 ` [PATCH v5 10/12] intel-mid: sfi: allow struct devs_id.get_platform_data to be NULL David Cohen
2013-10-17 18:19   ` [tip:x86/intel-mid] " tip-bot for David Cohen
2013-10-16  4:11 ` [PATCH v5 11/12] x86: intel-mid: add section for sfi device table David Cohen
2013-10-17 18:20   ` [tip:x86/intel-mid] " tip-bot for David Cohen
2013-10-16  4:11 ` [PATCH v5 12/12] intel_mid: Moved board related code to a new file David Cohen
2013-10-16 23:13   ` [PATCH v6 " David Cohen
2013-10-16 23:45     ` [PATCH v7 12/12] intel_mid: move board related code to their own platform_<device>.* files David Cohen
2013-10-17  2:36       ` [PATCH v8 12/12] intel_mid: move board related codes " David Cohen
2013-10-17 18:20         ` [tip:x86/intel-mid] intel_mid: move platform device definitions " tip-bot for David Cohen
2013-10-17 22:35 [PATCH v10 10/12] intel-mid: sfi: allow struct devs_id.get_platform_data to be NULL David Cohen
2013-10-18  0:34 ` [tip:x86/intel-mid] intel-mid: sfi: Allow " tip-bot for David Cohen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome