Skip to content

Commit c7f5da4

Browse files
committed
platform/x86: dell-smo8800: Move SMO88xx acpi_device_ids to dell-smo8800-ids.h
JIRA: https://issues.redhat.com/browse/RHEL-47426 commit bdf0ea9 Author: Hans de Goede <[email protected]> Date: Mon Dec 9 19:35:54 2024 +0100 platform/x86: dell-smo8800: Move SMO88xx acpi_device_ids to dell-smo8800-ids.h Move the SMO88xx acpi_device_ids to a new dell-smo8800-ids.h header, so that these can be shared with the new dell-lis3lv02d code. Reviewed-by: Pali Rohár <[email protected]> Signed-off-by: Hans de Goede <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ilpo Järvinen <[email protected]> Signed-off-by: Ilpo Järvinen <[email protected]> Signed-off-by: David Arcari <[email protected]>
1 parent 86e9f00 commit c7f5da4

File tree

2 files changed

+28
-15
lines changed

2 files changed

+28
-15
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/* SPDX-License-Identifier: GPL-2.0-or-later */
2+
/*
3+
* ACPI SMO88XX lis3lv02d freefall / accelerometer device-ids.
4+
*
5+
* Copyright (C) 2012 Sonal Santan <[email protected]>
6+
* Copyright (C) 2014 Pali Rohár <[email protected]>
7+
*/
8+
#ifndef _DELL_SMO8800_IDS_H_
9+
#define _DELL_SMO8800_IDS_H_
10+
11+
#include <linux/mod_devicetable.h>
12+
#include <linux/module.h>
13+
14+
static const struct acpi_device_id smo8800_ids[] = {
15+
{ "SMO8800" },
16+
{ "SMO8801" },
17+
{ "SMO8810" },
18+
{ "SMO8811" },
19+
{ "SMO8820" },
20+
{ "SMO8821" },
21+
{ "SMO8830" },
22+
{ "SMO8831" },
23+
{ }
24+
};
25+
MODULE_DEVICE_TABLE(acpi, smo8800_ids);
26+
27+
#endif

drivers/platform/x86/dell/dell-smo8800.c

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@
1414
#include <linux/interrupt.h>
1515
#include <linux/kernel.h>
1616
#include <linux/miscdevice.h>
17-
#include <linux/mod_devicetable.h>
1817
#include <linux/module.h>
1918
#include <linux/platform_device.h>
2019
#include <linux/uaccess.h>
20+
#include "dell-smo8800-ids.h"
2121

2222
struct smo8800_device {
2323
u32 irq; /* acpi device irq */
@@ -163,20 +163,6 @@ static void smo8800_remove(struct platform_device *device)
163163
dev_dbg(&device->dev, "device /dev/freefall unregistered\n");
164164
}
165165

166-
/* NOTE: Keep this list in sync with drivers/i2c/busses/i2c-i801.c */
167-
static const struct acpi_device_id smo8800_ids[] = {
168-
{ "SMO8800", 0 },
169-
{ "SMO8801", 0 },
170-
{ "SMO8810", 0 },
171-
{ "SMO8811", 0 },
172-
{ "SMO8820", 0 },
173-
{ "SMO8821", 0 },
174-
{ "SMO8830", 0 },
175-
{ "SMO8831", 0 },
176-
{ "", 0 },
177-
};
178-
MODULE_DEVICE_TABLE(acpi, smo8800_ids);
179-
180166
static struct platform_driver smo8800_driver = {
181167
.probe = smo8800_probe,
182168
.remove_new = smo8800_remove,

0 commit comments

Comments
 (0)