summaryrefslogtreecommitdiff
path: root/include/linux/spi/spi.h
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2021-03-16 17:55:41 +0000
committerMark Brown <broonie@kernel.org>2021-03-16 17:55:41 +0000
commit4152c4d0d939e6863f9814d7d346787b19f771f7 (patch)
treec7b0b19bc3316b29ec4666ea92500f00596787b4 /include/linux/spi/spi.h
parentd11233e0dee693fa28cd5023a0e4a212f4c80ed4 (diff)
parentdf41a5dad586c8ead1bb7082b4b6fcb563e02199 (diff)
Merge series "spi: Adding support for software nodes" from Heikki Krogerus <heikki.krogerus@linux.intel.com>:
Hi, The older API used to supply additional device properties for the devices - so mainly the function device_add_properties() - is going to be removed. The reason why the API will be removed is because it gives false impression that the properties are assigned directly to the devices, which has actually never been the case - the properties have always been assigned to a software fwnode which was then just directly linked with the device when the old API was used. By only accepting device properties instead of complete software nodes, the subsystems remove any change of taking advantage of the other features the software nodes have. The change that is required from the spi subsystem and the drivers is trivial. Basically only the "properties" member in struct spi_board_info, which was a pointer to struct property_entry, is replaced with a pointer to a complete software node. thanks, Heikki Krogerus (4): spi: Add support for software nodes ARM: pxa: icontrol: Constify the software node ARM: pxa: zeus: Constify the software node spi: Remove support for dangling device properties arch/arm/mach-pxa/icontrol.c | 12 ++++++++---- arch/arm/mach-pxa/zeus.c | 6 +++++- drivers/spi/spi.c | 21 ++++++--------------- include/linux/spi/spi.h | 7 +++---- 4 files changed, 22 insertions(+), 24 deletions(-) -- 2.30.1 base-commit: a38fd8748464831584a19438cbb3082b5a2dab15
Diffstat (limited to 'include/linux/spi/spi.h')
-rw-r--r--include/linux/spi/spi.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/include/linux/spi/spi.h b/include/linux/spi/spi.h
index ea1784a43267..6d5b1866cc89 100644
--- a/include/linux/spi/spi.h
+++ b/include/linux/spi/spi.h
@@ -19,7 +19,7 @@
#include <uapi/linux/spi/spi.h>
struct dma_chan;
-struct property_entry;
+struct software_node;
struct spi_controller;
struct spi_transfer;
struct spi_controller_mem_ops;
@@ -1397,7 +1397,7 @@ static inline ssize_t spi_w8r16be(struct spi_device *spi, u8 cmd)
* @modalias: Initializes spi_device.modalias; identifies the driver.
* @platform_data: Initializes spi_device.platform_data; the particular
* data stored there is driver-specific.
- * @properties: Additional device properties for the device.
+ * @swnode: Software node for the device.
* @controller_data: Initializes spi_device.controller_data; some
* controllers need hints about hardware setup, e.g. for DMA.
* @irq: Initializes spi_device.irq; depends on how the board is wired.
@@ -1430,12 +1430,11 @@ struct spi_board_info {
*
* platform_data goes to spi_device.dev.platform_data,
* controller_data goes to spi_device.controller_data,
- * device properties are copied and attached to spi_device,
* irq is copied too
*/
char modalias[SPI_NAME_SIZE];
const void *platform_data;
- const struct property_entry *properties;
+ const struct software_node *swnode;
void *controller_data;
int irq;