From: Dan Carpenter <dan.carpenter@oracle.com>
To: maxime.ripard@free-electrons.com
Cc: linux-clk@vger.kernel.org
Subject: re: clk: sunxi: Add TCON channel1 clock
Date: Sat, 23 Apr 2016 13:25:16 +0300 [thread overview]
Message-ID: <20160423102516.GA14424@mwanda> (raw)
Hello Maxime Ripard,
The patch cc510c736b1b: "clk: sunxi: Add TCON channel1 clock" from
Jul 1, 2015, leads to the following static checker warning:
drivers/clk/sunxi/clk-sun4i-tcon-ch1.c:89 tcon_ch1_get_parent()
warn: signedness bug returning '(-22)'
drivers/clk/sunxi/clk-sun4i-tcon-ch1.c
79 static u8 tcon_ch1_get_parent(struct clk_hw *hw)
^^
Is u8.
80 {
81 struct tcon_ch1_clk *tclk = hw_to_tclk(hw);
82 int num_parents = clk_hw_get_num_parents(hw);
83 u32 reg;
84
85 reg = readl(tclk->reg) >> TCON_CH1_SCLK2_MUX_SHIFT;
86 reg &= reg >> TCON_CH1_SCLK2_MUX_MASK;
87
88 if (reg >= num_parents)
89 return -EINVAL;
^^^^^^^^^^^^^^
Can't fit.
90
91 return reg;
92 }
regards,
dan carpenter
reply other threads:[~2016-04-23 10:25 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20160423102516.GA14424@mwanda \
--to=dan.carpenter@oracle.com \
--cc=linux-clk@vger.kernel.org \
--cc=maxime.ripard@free-electrons.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.