Skip to content

Commit 4590d98

Browse files
andy-shevrafaeljw
authored andcommitted
sfi: Remove framework for deprecated firmware
SFI-based platforms are gone. So does this framework. This removes mention of SFI through the drivers and other code as well. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 73f70d6 commit 4590d98

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+14
-2695
lines changed

Documentation/ABI/testing/sysfs-firmware-sfi

Lines changed: 0 additions & 15 deletions
This file was deleted.

Documentation/ABI/testing/sysfs-platform-kim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Description:
77
is connected. example: "/dev/ttyS0".
88

99
The device name flows down to architecture specific board
10-
initialization file from the SFI/ATAGS bootloader
10+
initialization file from the ATAGS bootloader
1111
firmware. The name exposed is read from the user-space
1212
dameon and opens the device when install is requested.
1313

MAINTAINERS

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16234,13 +16234,6 @@ S: Maintained
1623416234
F: Documentation/fb/sm712fb.rst
1623516235
F: drivers/video/fbdev/sm712*
1623616236

16237-
SIMPLE FIRMWARE INTERFACE (SFI)
16238-
S: Obsolete
16239-
W: http://simplefirmware.org/
16240-
F: arch/x86/platform/sfi/
16241-
F: drivers/sfi/
16242-
F: include/linux/sfi*.h
16243-
1624416237
SIMPLEFB FB DRIVER
1624516238
M: Hans de Goede <hdegoede@redhat.com>
1624616239
L: linux-fbdev@vger.kernel.org

arch/x86/Kconfig

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -444,7 +444,7 @@ config X86_X2APIC
444444
If you don't know what to do here, say N.
445445

446446
config X86_MPPARSE
447-
bool "Enable MPS table" if ACPI || SFI
447+
bool "Enable MPS table" if ACPI
448448
default y
449449
depends on X86_LOCAL_APIC
450450
help
@@ -603,7 +603,6 @@ config X86_INTEL_MID
603603
depends on PCI
604604
depends on X86_64 || (PCI_GOANY && X86_32)
605605
depends on X86_IO_APIC
606-
select SFI
607606
select I2C
608607
select DW_APB_TIMER
609608
select APB_TIMER
@@ -2457,8 +2456,6 @@ source "kernel/power/Kconfig"
24572456

24582457
source "drivers/acpi/Kconfig"
24592458

2460-
source "drivers/sfi/Kconfig"
2461-
24622459
config X86_APM_BOOT
24632460
def_bool y
24642461
depends on APM
@@ -2645,7 +2642,7 @@ config PCI_DIRECT
26452642
config PCI_MMCONFIG
26462643
bool "Support mmconfig PCI config space access" if X86_64
26472644
default y
2648-
depends on PCI && (ACPI || SFI || JAILHOUSE_GUEST)
2645+
depends on PCI && (ACPI || JAILHOUSE_GUEST)
26492646
depends on X86_64 || (PCI_GOANY || PCI_GOMMCONFIG)
26502647

26512648
config PCI_OLPC

arch/x86/include/asm/intel-mid.h

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
#ifndef _ASM_X86_INTEL_MID_H
88
#define _ASM_X86_INTEL_MID_H
99

10-
#include <linux/sfi.h>
1110
#include <linux/pci.h>
1211
#include <linux/platform_device.h>
1312

@@ -22,39 +21,6 @@ extern void intel_mid_pwr_power_off(void);
2221

2322
extern int intel_mid_pwr_get_lss_id(struct pci_dev *pdev);
2423

25-
extern int get_gpio_by_name(const char *name);
26-
27-
/*
28-
* Here defines the array of devices platform data that IAFW would export
29-
* through SFI "DEVS" table, we use name and type to match the device and
30-
* its platform data.
31-
*/
32-
struct devs_id {
33-
char name[SFI_NAME_LEN + 1];
34-
u8 type;
35-
u8 delay;
36-
void *(*get_platform_data)(void *info);
37-
};
38-
39-
#define sfi_device(i) \
40-
static const struct devs_id *const __intel_mid_sfi_##i##_dev __used \
41-
__section(".x86_intel_mid_dev.init") = &i
42-
43-
/**
44-
* struct mid_sd_board_info - template for SD device creation
45-
* @name: identifies the driver
46-
* @bus_num: board-specific identifier for a given SD controller
47-
* @max_clk: the maximum frequency device supports
48-
* @platform_data: the particular data stored there is driver-specific
49-
*/
50-
struct mid_sd_board_info {
51-
char name[SFI_NAME_LEN];
52-
int bus_num;
53-
unsigned short addr;
54-
u32 max_clk;
55-
void *platform_data;
56-
};
57-
5824
/*
5925
* Medfield is the follow-up of Moorestown, it combines two chip solution into
6026
* one. Other than that it also added always-on and constant tsc and lapic
@@ -99,7 +65,4 @@ static inline void intel_scu_devices_destroy(void) { }
9965
/* FSB 83MHz */
10066
#define BSEL_SOC_FUSE_111 0x7
10167

102-
/* The offset for the mapping of global gpio pin to irq */
103-
#define INTEL_MID_IRQ_OFFSET 0x100
104-
10568
#endif /* _ASM_X86_INTEL_MID_H */

arch/x86/include/asm/intel_scu_ipc_legacy.h

Lines changed: 1 addition & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -2,73 +2,17 @@
22
#ifndef _ASM_X86_INTEL_SCU_IPC_LEGACY_H_
33
#define _ASM_X86_INTEL_SCU_IPC_LEGACY_H_
44

5-
#include <linux/notifier.h>
6-
7-
#define IPCMSG_INDIRECT_READ 0x02
8-
#define IPCMSG_INDIRECT_WRITE 0x05
5+
#include <linux/types.h>
96

107
#define IPCMSG_COLD_OFF 0x80 /* Only for Tangier */
11-
12-
#define IPCMSG_WARM_RESET 0xF0
138
#define IPCMSG_COLD_RESET 0xF1
14-
#define IPCMSG_SOFT_RESET 0xF2
15-
#define IPCMSG_COLD_BOOT 0xF3
169

1710
/* Don't call these in new code - they will be removed eventually */
1811

19-
/* Read a vector */
20-
static inline int intel_scu_ipc_readv(u16 *addr, u8 *data, int len)
21-
{
22-
return intel_scu_ipc_dev_readv(NULL, addr, data, len);
23-
}
24-
25-
/* Write a vector */
26-
static inline int intel_scu_ipc_writev(u16 *addr, u8 *data, int len)
27-
{
28-
return intel_scu_ipc_dev_writev(NULL, addr, data, len);
29-
}
30-
31-
/* Update single register based on the mask */
32-
static inline int intel_scu_ipc_update_register(u16 addr, u8 data, u8 mask)
33-
{
34-
return intel_scu_ipc_dev_update(NULL, addr, data, mask);
35-
}
36-
3712
/* Issue commands to the SCU with or without data */
3813
static inline int intel_scu_ipc_simple_command(int cmd, int sub)
3914
{
4015
return intel_scu_ipc_dev_simple_command(NULL, cmd, sub);
4116
}
4217

43-
static inline int intel_scu_ipc_command(int cmd, int sub, u32 *in, int inlen,
44-
u32 *out, int outlen)
45-
{
46-
/* New API takes both inlen and outlen as bytes so convert here */
47-
size_t inbytes = inlen * sizeof(u32);
48-
size_t outbytes = outlen * sizeof(u32);
49-
50-
return intel_scu_ipc_dev_command_with_size(NULL, cmd, sub, in, inbytes,
51-
inlen, out, outbytes);
52-
}
53-
54-
extern struct blocking_notifier_head intel_scu_notifier;
55-
56-
static inline void intel_scu_notifier_add(struct notifier_block *nb)
57-
{
58-
blocking_notifier_chain_register(&intel_scu_notifier, nb);
59-
}
60-
61-
static inline void intel_scu_notifier_remove(struct notifier_block *nb)
62-
{
63-
blocking_notifier_chain_unregister(&intel_scu_notifier, nb);
64-
}
65-
66-
static inline int intel_scu_notifier_post(unsigned long v, void *p)
67-
{
68-
return blocking_notifier_call_chain(&intel_scu_notifier, v, p);
69-
}
70-
71-
#define SCU_AVAILABLE 1
72-
#define SCU_DOWN 2
73-
7418
#endif

arch/x86/include/asm/platform_sst_audio.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010
#ifndef _PLATFORM_SST_AUDIO_H_
1111
#define _PLATFORM_SST_AUDIO_H_
1212

13-
#include <linux/sfi.h>
14-
1513
#define MAX_NUM_STREAMS_MRFLD 25
1614
#define MAX_NUM_STREAMS MAX_NUM_STREAMS_MRFLD
1715

arch/x86/kernel/apic/io_apic.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ static int __init parse_noapic(char *str)
198198
}
199199
early_param("noapic", parse_noapic);
200200

201-
/* Will be called in mpparse/acpi/sfi codes for saving IRQ info */
201+
/* Will be called in mpparse/ACPI codes for saving IRQ info */
202202
void mp_save_irq(struct mpc_intsrc *m)
203203
{
204204
int i;
@@ -2863,7 +2863,7 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base,
28632863

28642864
/*
28652865
* If mp_register_ioapic() is called during early boot stage when
2866-
* walking ACPI/SFI/DT tables, it's too early to create irqdomain,
2866+
* walking ACPI/DT tables, it's too early to create irqdomain,
28672867
* we are still using bootmem allocator. So delay it to setup_IO_APIC().
28682868
*/
28692869
if (hotplug) {

arch/x86/kernel/setup.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include <linux/memblock.h>
1717
#include <linux/pci.h>
1818
#include <linux/root_dev.h>
19-
#include <linux/sfi.h>
2019
#include <linux/hugetlb.h>
2120
#include <linux/tboot.h>
2221
#include <linux/usb/xhci-dbgp.h>
@@ -1185,7 +1184,6 @@ void __init setup_arch(char **cmdline_p)
11851184
* Read APIC and some other early information from ACPI tables.
11861185
*/
11871186
acpi_boot_init();
1188-
sfi_init();
11891187
x86_dtb_init();
11901188

11911189
/*

arch/x86/pci/mmconfig-shared.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
* themselves.
1212
*/
1313

14+
#include <linux/acpi.h>
1415
#include <linux/pci.h>
1516
#include <linux/init.h>
16-
#include <linux/sfi_acpi.h>
1717
#include <linux/bitmap.h>
1818
#include <linux/dmi.h>
1919
#include <linux/slab.h>
@@ -665,7 +665,7 @@ void __init pci_mmcfg_early_init(void)
665665
if (pci_mmcfg_check_hostbridge())
666666
known_bridge = 1;
667667
else
668-
acpi_sfi_table_parse(ACPI_SIG_MCFG, pci_parse_mcfg);
668+
acpi_table_parse(ACPI_SIG_MCFG, pci_parse_mcfg);
669669
__pci_mmcfg_init(1);
670670

671671
set_apei_filter();
@@ -683,7 +683,7 @@ void __init pci_mmcfg_late_init(void)
683683

684684
/* MMCONFIG hasn't been enabled yet, try again */
685685
if (pci_probe & PCI_PROBE_MASK & ~PCI_PROBE_MMCONF) {
686-
acpi_sfi_table_parse(ACPI_SIG_MCFG, pci_parse_mcfg);
686+
acpi_table_parse(ACPI_SIG_MCFG, pci_parse_mcfg);
687687
__pci_mmcfg_init(0);
688688
}
689689
}

0 commit comments

Comments
 (0)