mirror of
https://github.com/torvalds/linux.git
synced 2024-11-21 11:35:45 +00:00
logic_pio: Constify fwnode_handle
The fwnode_handle passed into find_io_range_by_fwnode() and logic_pio_trans_hwaddr() are not modified, so make them const. Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20241010-dt-const-v1-2-87a51f558425@kernel.org Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
This commit is contained in:
parent
1d31c6fc86
commit
6ba55951e7
@ -17,7 +17,7 @@ enum {
|
||||
|
||||
struct logic_pio_hwaddr {
|
||||
struct list_head list;
|
||||
struct fwnode_handle *fwnode;
|
||||
const struct fwnode_handle *fwnode;
|
||||
resource_size_t hw_start;
|
||||
resource_size_t io_start;
|
||||
resource_size_t size; /* range size populated */
|
||||
@ -110,8 +110,8 @@ void logic_outsl(unsigned long addr, const void *buffer, unsigned int count);
|
||||
#endif /* CONFIG_INDIRECT_PIO */
|
||||
#define MMIO_UPPER_LIMIT (IO_SPACE_LIMIT - PIO_INDIRECT_SIZE)
|
||||
|
||||
struct logic_pio_hwaddr *find_io_range_by_fwnode(struct fwnode_handle *fwnode);
|
||||
unsigned long logic_pio_trans_hwaddr(struct fwnode_handle *fwnode,
|
||||
struct logic_pio_hwaddr *find_io_range_by_fwnode(const struct fwnode_handle *fwnode);
|
||||
unsigned long logic_pio_trans_hwaddr(const struct fwnode_handle *fwnode,
|
||||
resource_size_t hw_addr, resource_size_t size);
|
||||
int logic_pio_register_range(struct logic_pio_hwaddr *newrange);
|
||||
void logic_pio_unregister_range(struct logic_pio_hwaddr *range);
|
||||
|
@ -122,7 +122,7 @@ void logic_pio_unregister_range(struct logic_pio_hwaddr *range)
|
||||
*
|
||||
* Traverse the io_range_list to find the registered node for @fwnode.
|
||||
*/
|
||||
struct logic_pio_hwaddr *find_io_range_by_fwnode(struct fwnode_handle *fwnode)
|
||||
struct logic_pio_hwaddr *find_io_range_by_fwnode(const struct fwnode_handle *fwnode)
|
||||
{
|
||||
struct logic_pio_hwaddr *range, *found_range = NULL;
|
||||
|
||||
@ -186,7 +186,7 @@ resource_size_t logic_pio_to_hwaddr(unsigned long pio)
|
||||
*
|
||||
* Returns Logical PIO value if successful, ~0UL otherwise
|
||||
*/
|
||||
unsigned long logic_pio_trans_hwaddr(struct fwnode_handle *fwnode,
|
||||
unsigned long logic_pio_trans_hwaddr(const struct fwnode_handle *fwnode,
|
||||
resource_size_t addr, resource_size_t size)
|
||||
{
|
||||
struct logic_pio_hwaddr *range;
|
||||
|
Loading…
Reference in New Issue
Block a user