Skip to contentSkip to conversation

x86/platform/intel-mid: Remove Moorestown code

PATCH New Andy Shevchenko 2 participants 4 messages Jan 5, 2017 – Jan 6, 2017

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 x86/platform/intel-mid: Remove Moorestown code

The Moorestown support was removed by commit 1a8359e411eb ("x86/mid: Remove Intel Moorestown").

Remove this leftover.

---
 arch/x86/platform/intel-mid/device_libs/Makefile   |  1 -
 .../platform/intel-mid/device_libs/platform_ipc.c  |  9 ----
 .../intel-mid/device_libs/platform_pmic_gpio.c     | 54 ----------------------
 3 files changed, 64 deletions(-)
 delete mode 100644 arch/x86/platform/intel-mid/device_libs/platform_pmic_gpio.c
arch/x86/platform/intel-mid/device_libs/Makefile +0 -1
index a779d84e5f50..ccbb86f3080d 100644
@@ -13,7 +13,6 @@ obj-$(subst m,y,$(CONFIG_GPIO_MSIC)) += platform_msic_gpio.o
 obj-$(subst m,y,$(CONFIG_MFD_INTEL_MSIC)) += platform_msic_ocd.o
 obj-$(subst m,y,$(CONFIG_MFD_INTEL_MSIC)) += platform_msic_battery.o
 obj-$(subst m,y,$(CONFIG_INTEL_MID_POWER_BUTTON)) += platform_msic_power_btn.o
-obj-$(subst m,y,$(CONFIG_GPIO_INTEL_PMIC)) += platform_pmic_gpio.o
 obj-$(subst m,y,$(CONFIG_INTEL_MFLD_THERMAL)) += platform_msic_thermal.o
 # SPI Devices
 #obj-$(subst m,y,$(CONFIG_SPI_SPIDEV)) += platform_mrfld_spidev.o
arch/x86/platform/intel-mid/device_libs/platform_ipc.c +0 -9
index a84b73d6c4a0..a428c051e7bb 100644
@@ -57,12 +57,3 @@ void __init ipc_device_handler(struct sfi_device_table_entry *pentry,
 	pdev->dev.platform_data = pdata;
 	intel_scu_device_register(pdev);
 }
-
-static const struct devs_id pmic_audio_dev_id __initconst = {
-	.name = "pmic_audio",
-	.type = SFI_DEV_TYPE_IPC,
-	.delay = 1,
-	.device_handler = &ipc_device_handler,
-};
-
-sfi_device(pmic_audio_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_pmic_gpio.c deleted +0 -54

54 lines not on this page · raw message

Signature · 1 line
2.11.0
#1 lore raw

PATCH 2/2 x86/platform/intel-mid: Get rid of duplication of IPC handler

There is no other device handler than ipc_device_handler() and sfi.c already has a handler for IPC devices.

Replace a pointer to custom handler by a flag. Due to this change adjust sfi_handle_ipc_dev() to handle it instead of ipc_device_handler().

---
 arch/x86/include/asm/intel-mid.h                   |  4 +-
 arch/x86/platform/intel-mid/device_libs/Makefile   |  1 -
 .../platform/intel-mid/device_libs/platform_ipc.c  | 59 ----------------------
 .../platform/intel-mid/device_libs/platform_ipc.h  | 18 -------
 .../intel-mid/device_libs/platform_msic_audio.c    |  3 +-
 .../intel-mid/device_libs/platform_msic_battery.c  |  3 +-
 .../intel-mid/device_libs/platform_msic_gpio.c     |  3 +-
 .../intel-mid/device_libs/platform_msic_ocd.c      |  3 +-
 .../device_libs/platform_msic_power_btn.c          |  3 +-
 .../intel-mid/device_libs/platform_msic_thermal.c  |  3 +-
 arch/x86/platform/intel-mid/sfi.c                  | 55 ++++++++++++--------
 11 files changed, 40 insertions(+), 115 deletions(-)
 delete mode 100644 arch/x86/platform/intel-mid/device_libs/platform_ipc.c
 delete mode 100644 arch/x86/platform/intel-mid/device_libs/platform_ipc.h
arch/x86/include/asm/intel-mid.h +1 -3
index 49da9f497b90..91ead0cefa76 100644
@@ -42,10 +42,8 @@ struct devs_id {
 	char name[SFI_NAME_LEN + 1];
 	u8 type;
 	u8 delay;
+	u8 msic;
 	void *(*get_platform_data)(void *info);
-	/* Custom handler for devices */
-	void (*device_handler)(struct sfi_device_table_entry *pentry,
-			       struct devs_id *dev);
 };
 
 #define sfi_device(i)								\
arch/x86/platform/intel-mid/device_libs/Makefile +0 -1
index ccbb86f3080d..8be58eefb281 100644
@@ -6,7 +6,6 @@ obj-$(subst m,y,$(CONFIG_MMC_SDHCI_PCI)) += platform_mrfld_sd.o
 obj-$(subst m,y,$(CONFIG_BRCMFMAC_SDIO)) += platform_bcm43xx.o
 obj-$(subst m,y,$(CONFIG_BT_HCIUART_BCM)) += platform_bt.o
 # IPC Devices
-obj-y += platform_ipc.o
 obj-$(subst m,y,$(CONFIG_MFD_INTEL_MSIC)) += platform_msic.o
 obj-$(subst m,y,$(CONFIG_SND_MFLD_MACHINE)) += platform_msic_audio.o
 obj-$(subst m,y,$(CONFIG_GPIO_MSIC)) += platform_msic_gpio.o
arch/x86/platform/intel-mid/device_libs/platform_ipc.c deleted +0 -59

59 lines not on this page · raw message

arch/x86/platform/intel-mid/device_libs/platform_ipc.h deleted +0 -18
deleted file mode 100644
index 79bb09d4f718..000000000000
@@ -1,18 +0,0 @@
-/*
- * platform_ipc.h: IPC platform library header file
- *
- * (C) Copyright 2013 Intel Corporation
- * Author: Sathyanarayanan Kuppuswamy <[email protected]>
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; version 2
- * of the License.
- */
-#ifndef _PLATFORM_IPC_H_
-#define _PLATFORM_IPC_H_
-
-void __init
-ipc_device_handler(struct sfi_device_table_entry *pentry, struct devs_id *dev);
-
-#endif
arch/x86/platform/intel-mid/device_libs/platform_msic_audio.c +1 -2
index cb3490ecb341..d4dc744dd5a5 100644
@@ -20,7 +20,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void *msic_audio_platform_data(void *info)
 {
@@ -40,8 +39,8 @@ static const struct devs_id msic_audio_dev_id __initconst = {
 	.name = "msic_audio",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_audio_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_audio_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_battery.c +1 -2
index 4f72193939a6..5c3e9919633f 100644
@@ -19,7 +19,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_battery_platform_data(void *info)
 {
@@ -30,8 +29,8 @@ static const struct devs_id msic_battery_dev_id __initconst = {
 	.name = "msic_battery",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_battery_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_battery_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_gpio.c +1 -2
index 70de5b531ba0..9fdb88d460d7 100644
@@ -20,7 +20,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_gpio_platform_data(void *info)
 {
@@ -41,8 +40,8 @@ static const struct devs_id msic_gpio_dev_id __initconst = {
 	.name = "msic_gpio",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_gpio_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_gpio_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_ocd.c +1 -2
index 3d7c2011b6cf..7ae37cdbf256 100644
@@ -20,7 +20,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_ocd_platform_data(void *info)
 {
@@ -42,8 +41,8 @@ static const struct devs_id msic_ocd_dev_id __initconst = {
 	.name = "msic_ocd",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_ocd_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_ocd_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_power_btn.c +1 -2
index 038f618fbc52..96809b98cf69 100644
@@ -18,7 +18,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_power_btn_platform_data(void *info)
 {
@@ -29,8 +28,8 @@ static const struct devs_id msic_power_btn_dev_id __initconst = {
 	.name = "msic_power_btn",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_power_btn_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_power_btn_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_thermal.c +1 -2
index 114a5755b1e4..3e4167d246cd 100644
@@ -19,7 +19,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_thermal_platform_data(void *info)
 {
@@ -30,8 +29,8 @@ static const struct devs_id msic_thermal_dev_id __initconst = {
 	.name = "msic_thermal",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_thermal_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_thermal_dev_id);
arch/x86/platform/intel-mid/sfi.c +33 -22

77 lines not on this page · raw message

Signature · 1 line
2.11.0
#2 lore raw

[tip:x86/platform] x86/platform/intel-mid: Get rid of duplication of IPC handler

x86/platform/intel-mid: Get rid of duplication of IPC handler
Commit-ID:  a01b3391b542aaaed539f9d9d6d0d4d6502ab9c6
Gitweb:     http://git.kernel.org/tip/a01b3391b542aaaed539f9d9d6d0d4d6502ab9c6
Author:     Andy Shevchenko <[email protected]>
AuthorDate: Thu, 5 Jan 2017 15:02:35 +0200
Committer:  Ingo Molnar <[email protected]>
CommitDate: Fri, 6 Jan 2017 08:35:27 +0100

x86/platform/intel-mid: Get rid of duplication of IPC handler

There is no other device handler than ipc_device_handler() and sfi.c already has a handler for IPC devices.

Replace a pointer to custom handler by a flag. Due to this change adjust sfi_handle_ipc_dev() to handle it instead of ipc_device_handler().

---
 arch/x86/include/asm/intel-mid.h                   |  4 +-
 arch/x86/platform/intel-mid/device_libs/Makefile   |  1 -
 .../platform/intel-mid/device_libs/platform_ipc.c  | 59 ----------------------
 .../platform/intel-mid/device_libs/platform_ipc.h  | 18 -------
 .../intel-mid/device_libs/platform_msic_audio.c    |  3 +-
 .../intel-mid/device_libs/platform_msic_battery.c  |  3 +-
 .../intel-mid/device_libs/platform_msic_gpio.c     |  3 +-
 .../intel-mid/device_libs/platform_msic_ocd.c      |  3 +-
 .../device_libs/platform_msic_power_btn.c          |  3 +-
 .../intel-mid/device_libs/platform_msic_thermal.c  |  3 +-
 arch/x86/platform/intel-mid/sfi.c                  | 55 ++++++++++++--------
 11 files changed, 40 insertions(+), 115 deletions(-)
arch/x86/include/asm/intel-mid.h +1 -3
index 49da9f4..91ead0c 100644
@@ -42,10 +42,8 @@ struct devs_id {
 	char name[SFI_NAME_LEN + 1];
 	u8 type;
 	u8 delay;
+	u8 msic;
 	void *(*get_platform_data)(void *info);
-	/* Custom handler for devices */
-	void (*device_handler)(struct sfi_device_table_entry *pentry,
-			       struct devs_id *dev);
 };
 
 #define sfi_device(i)								\
arch/x86/platform/intel-mid/device_libs/Makefile +0 -1
index 4d8c14a..d4af778 100644
@@ -5,7 +5,6 @@ obj-$(subst m,y,$(CONFIG_MMC_SDHCI_PCI)) += platform_mrfld_sd.o
 # WiFi
 obj-$(subst m,y,$(CONFIG_BRCMFMAC_SDIO)) += platform_bcm43xx.o
 # IPC Devices
-obj-y += platform_ipc.o
 obj-$(subst m,y,$(CONFIG_MFD_INTEL_MSIC)) += platform_msic.o
 obj-$(subst m,y,$(CONFIG_SND_MFLD_MACHINE)) += platform_msic_audio.o
 obj-$(subst m,y,$(CONFIG_GPIO_MSIC)) += platform_msic_gpio.o
arch/x86/platform/intel-mid/device_libs/platform_ipc.c deleted +0 -59

59 lines not on this page · raw message

arch/x86/platform/intel-mid/device_libs/platform_ipc.h deleted +0 -18
deleted file mode 100644
index 79bb09d..0000000
@@ -1,18 +0,0 @@
-/*
- * platform_ipc.h: IPC platform library header file
- *
- * (C) Copyright 2013 Intel Corporation
- * Author: Sathyanarayanan Kuppuswamy <[email protected]>
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; version 2
- * of the License.
- */
-#ifndef _PLATFORM_IPC_H_
-#define _PLATFORM_IPC_H_
-
-void __init
-ipc_device_handler(struct sfi_device_table_entry *pentry, struct devs_id *dev);
-
-#endif
arch/x86/platform/intel-mid/device_libs/platform_msic_audio.c +1 -2
index cb3490ec..d4dc744 100644
@@ -20,7 +20,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void *msic_audio_platform_data(void *info)
 {
@@ -40,8 +39,8 @@ static const struct devs_id msic_audio_dev_id __initconst = {
 	.name = "msic_audio",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_audio_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_audio_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_battery.c +1 -2
index 4f72193..5c3e991 100644
@@ -19,7 +19,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_battery_platform_data(void *info)
 {
@@ -30,8 +29,8 @@ static const struct devs_id msic_battery_dev_id __initconst = {
 	.name = "msic_battery",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_battery_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_battery_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_gpio.c +1 -2
index 70de5b5..9fdb88d 100644
@@ -20,7 +20,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_gpio_platform_data(void *info)
 {
@@ -41,8 +40,8 @@ static const struct devs_id msic_gpio_dev_id __initconst = {
 	.name = "msic_gpio",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_gpio_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_gpio_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_ocd.c +1 -2
index 3d7c201..7ae37cd 100644
@@ -20,7 +20,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_ocd_platform_data(void *info)
 {
@@ -42,8 +41,8 @@ static const struct devs_id msic_ocd_dev_id __initconst = {
 	.name = "msic_ocd",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_ocd_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_ocd_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_power_btn.c +1 -2
index 038f618..96809b9 100644
@@ -18,7 +18,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_power_btn_platform_data(void *info)
 {
@@ -29,8 +28,8 @@ static const struct devs_id msic_power_btn_dev_id __initconst = {
 	.name = "msic_power_btn",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_power_btn_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_power_btn_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_msic_thermal.c +1 -2
index 114a575..3e4167d 100644
@@ -19,7 +19,6 @@
 #include <asm/intel-mid.h>
 
 #include "platform_msic.h"
-#include "platform_ipc.h"
 
 static void __init *msic_thermal_platform_data(void *info)
 {
@@ -30,8 +29,8 @@ static const struct devs_id msic_thermal_dev_id __initconst = {
 	.name = "msic_thermal",
 	.type = SFI_DEV_TYPE_IPC,
 	.delay = 1,
+	.msic = 1,
 	.get_platform_data = &msic_thermal_platform_data,
-	.device_handler = &ipc_device_handler,
 };
 
 sfi_device(msic_thermal_dev_id);
arch/x86/platform/intel-mid/sfi.c +33 -22

77 lines not on this page · raw message

#3 lore raw
In reply to Andy Shevchenko
x86/platform/intel-mid: Remove Moorestown code
Commit-ID:  4b5b61eaf8b70838750a1e6dc80ecd044c8f4b3f
Gitweb:     http://git.kernel.org/tip/4b5b61eaf8b70838750a1e6dc80ecd044c8f4b3f
Author:     Andy Shevchenko <[email protected]>
AuthorDate: Thu, 5 Jan 2017 15:02:34 +0200
Committer:  Ingo Molnar <[email protected]>
CommitDate: Fri, 6 Jan 2017 08:35:27 +0100

x86/platform/intel-mid: Remove Moorestown code

The Moorestown support code was removed by:

a8359e411eb ("x86/mid: Remove Intel Moorestown").

Remove this leftover as well.

---
 arch/x86/platform/intel-mid/device_libs/Makefile   |  1 -
 .../platform/intel-mid/device_libs/platform_ipc.c  |  9 ----
 .../intel-mid/device_libs/platform_pmic_gpio.c     | 54 ----------------------
 3 files changed, 64 deletions(-)
arch/x86/platform/intel-mid/device_libs/Makefile +0 -1
index 90e4f2a..4d8c14a 100644
@@ -12,7 +12,6 @@ obj-$(subst m,y,$(CONFIG_GPIO_MSIC)) += platform_msic_gpio.o
 obj-$(subst m,y,$(CONFIG_MFD_INTEL_MSIC)) += platform_msic_ocd.o
 obj-$(subst m,y,$(CONFIG_MFD_INTEL_MSIC)) += platform_msic_battery.o
 obj-$(subst m,y,$(CONFIG_INTEL_MID_POWER_BUTTON)) += platform_msic_power_btn.o
-obj-$(subst m,y,$(CONFIG_GPIO_INTEL_PMIC)) += platform_pmic_gpio.o
 obj-$(subst m,y,$(CONFIG_INTEL_MFLD_THERMAL)) += platform_msic_thermal.o
 # SPI Devices
 obj-$(subst m,y,$(CONFIG_SPI_SPIDEV)) += platform_mrfld_spidev.o
arch/x86/platform/intel-mid/device_libs/platform_ipc.c +0 -9
index a84b73d..a428c05 100644
@@ -57,12 +57,3 @@ void __init ipc_device_handler(struct sfi_device_table_entry *pentry,
 	pdev->dev.platform_data = pdata;
 	intel_scu_device_register(pdev);
 }
-
-static const struct devs_id pmic_audio_dev_id __initconst = {
-	.name = "pmic_audio",
-	.type = SFI_DEV_TYPE_IPC,
-	.delay = 1,
-	.device_handler = &ipc_device_handler,
-};
-
-sfi_device(pmic_audio_dev_id);
arch/x86/platform/intel-mid/device_libs/platform_pmic_gpio.c deleted +0 -54

54 lines not on this page · raw message