From: "Michael J. Ruhl" <michael.j.ruhl@intel.com>
To: linux@armlinux.org.uk, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, andriy.shevchenko@linux.intel.com
Cc: "Michael J. Ruhl" <michael.j.ruhl@intel.com>
Subject: [PATCH] clkdev: Update clkdev id usage to allow for longer names
Date: Fri, 23 Feb 2024 09:18:14 -0500 [thread overview]
Message-ID: <20240223141857.3794855-1-michael.j.ruhl@intel.com> (raw)
clkdev ID information is limited to arrays of 20 and 16 bytes
(MAX_DEV_ID/MAX_CON_ID). It is possible that the IDs could be
longer that. If so, the lookup will fail because the "real ID"
will not match the copied value.
Increase the size of the IDs to allow for longer names.
Signed-off-by: Michael J. Ruhl <michael.j.ruhl@intel.com>
---
drivers/clk/clkdev.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/clk/clkdev.c b/drivers/clk/clkdev.c
index ee37d0be6877..38549db691f4 100644
--- a/drivers/clk/clkdev.c
+++ b/drivers/clk/clkdev.c
@@ -144,8 +144,8 @@ void clkdev_add_table(struct clk_lookup *cl, size_t num)
mutex_unlock(&clocks_mutex);
}
-#define MAX_DEV_ID 20
-#define MAX_CON_ID 16
+#define MAX_DEV_ID 32
+#define MAX_CON_ID 32
struct clk_lookup_alloc {
struct clk_lookup cl;
--
2.41.0
next reply other threads:[~2024-02-23 14:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-23 14:18 Michael J. Ruhl [this message]
2024-02-23 15:48 ` Andy Shevchenko
2024-02-23 16:09 ` Ruhl, Michael J
2024-02-23 16:19 ` Andy Shevchenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240223141857.3794855-1-michael.j.ruhl@intel.com \
--to=michael.j.ruhl@intel.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®