[PATCH v3 19/22] firmware: ti: ti_sci_clock: Move clock ops into its own file
Andrew Davis
afd at ti.com
Wed Dec 2 07:33:41 PST 2026
On 12/2/26 8:40 AM, Sebin Francis wrote:
> Hi Beleswar
>
> On 29/10/26 23:41, Beleswar Padhi wrote:
>> From: Andrew Davis <afd at ti.com>
>>
>> Extract the clock operations related functions and services from
>> ti_sci_core.c into its own file. This breaks down the single large
>> file into smaller logical files for better readability and maintenance.
>>
>> Signed-off-by: Andrew Davis <afd at ti.com>
>> Signed-off-by: Beleswar Padhi <b-padhi at ti.com>
>> ---
>> v3: Changelog:
>> 1. None to this patch.
>>
>> Link to v2:
>> https://lore.kernel.org/all/20260930160607.2674980-20-b-padhi@ti.com/
>>
>> v2: Changelog:
>> 1. None to this patch.
>>
>> Link to v1:
>> https://lore.kernel.org/all/20260929201746.4078803-20-b-padhi@ti.com/
>>
>> drivers/firmware/ti/Makefile | 1 +
>> drivers/firmware/ti/ti_sci.h | 1 +
>> drivers/firmware/ti/ti_sci_clock.c | 553 +++++++++++++++++++++++++++++
>> drivers/firmware/ti/ti_sci_core.c | 535 +---------------------------
>> 4 files changed, 556 insertions(+), 534 deletions(-)
>> create mode 100644 drivers/firmware/ti/ti_sci_clock.c
>>
>> diff --git a/drivers/firmware/ti/Makefile b/drivers/firmware/ti/Makefile
>> index a3a056eedd9a5..c4233542ad57d 100644
>> --- a/drivers/firmware/ti/Makefile
>> +++ b/drivers/firmware/ti/Makefile
>> @@ -1,5 +1,6 @@
>> # SPDX-License-Identifier: GPL-2.0-only
>> ti_sci-y := ti_sci_core.o
>> +ti_sci-y += ti_sci_clock.o
>> ti_sci-y += ti_sci_device.o
>> obj-$(CONFIG_TI_SCI_PROTOCOL) += ti_sci.o
>> diff --git a/drivers/firmware/ti/ti_sci.h b/drivers/firmware/ti/ti_sci.h
>> index 79f56699faf29..cce59cac35ed6 100644
>> --- a/drivers/firmware/ti/ti_sci.h
>> +++ b/drivers/firmware/ti/ti_sci.h
>> @@ -1566,5 +1566,6 @@ int ti_sci_do_xfer(const struct ti_sci_handle *handle,
>> void *rx_message, size_t rx_message_size);
>> void ti_sci_setup_device_ops(struct ti_sci_dev_ops *dops);
>> +void ti_sci_setup_clock_ops(struct ti_sci_clk_ops *cops);
>> #endif /* __TI_SCI_H */
>> diff --git a/drivers/firmware/ti/ti_sci_clock.c b/drivers/firmware/ti/ti_sci_clock.c
>> new file mode 100644
>> index 0000000000000..f266522fb7d08
>> --- /dev/null
>> +++ b/drivers/firmware/ti/ti_sci_clock.c
>> @@ -0,0 +1,553 @@
>> +// SPDX-License-Identifier: GPL-2.0
>> +/*
>> + * Texas Instruments System Control Interface Protocol Driver
>> + *
>> + * Copyright (C) 2015-2026 Texas Instruments Incorporated - https://www.ti.com/
>> + * Nishanth Menon
>> + */
>> +
>> +#include <linux/errno.h>
>
> is this required as the ti_sci_protocol.h includes linux/err.h?
>> +#include <linux/soc/ti/ti_sci_protocol.h>
>
> Also is this required? because ti_sci.h includes this
>
Probably not technically required, but it is always better to
include what you use, and not depend on transitive inclusions.
Andrew
> Sebin
>
>> +
>> +#include "ti_sci.h"
>> +
>> +/**
More information about the linux-arm-kernel
mailing list