From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefano Babic Date: Sat, 8 Jun 2019 17:22:33 +0200 Subject: [U-Boot] [PATCH v4 05/13] clk: Extend struct clk to provide clock type agnostic flags In-Reply-To: <20190516221042.3583-6-lukma@denx.de> References: <20190516221042.3583-1-lukma@denx.de> <20190516221042.3583-6-lukma@denx.de> Message-ID: <6ee42a24-e896-d14d-9ed2-ab91bd93c61e@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 17/05/19 00:10, Lukasz Majewski wrote: > This commit extends the struct clk to provide information regarding the > flags related to this devices. > > Those flags are clk device agnostic and indicate generic features > (like e.g. CLK_GET_RATE_NOCACHE - the need to always recalculate the rate). > > Signed-off-by: Lukasz Majewski > > --- > > Changes in v4: > - New patch > > Changes in v3: None > > include/clk.h | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/include/clk.h b/include/clk.h > index 1f2fd15bb5..89dc64bfaf 100644 > --- a/include/clk.h > +++ b/include/clk.h > @@ -41,6 +41,9 @@ struct udevice; > * > * @dev: The device which implements the clock signal. > * @rate: The clock rate (in HZ). > + * @flags: Flags used across common clock structure (e.g. CLK_) > + * Clock IP blocks specific flags (i.e. mux, div, gate, etc) are defined > + * in struct's for those devices (e.g. struct clk_mux). > * @id: The clock signal ID within the provider. > * @data: An optional data field for scenarios where a single integer ID is not > * sufficient. If used, it can be populated through an .of_xlate op and > @@ -57,6 +60,7 @@ struct udevice; > struct clk { > struct udevice *dev; > unsigned long rate; /* in HZ */ > + uint32_t flags; > /* > * Written by of_xlate. In the future, we might add more fields here. > */ > Reviewed-by: Stefano Babic Best regards, Stefano Babic -- ===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================