lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+M3ks4a=tg3SuE-OiotB_w7ijhvOiBSVfE32kVAx_WCOoMB1g@mail.gmail.com>
Date:   Tue, 28 Mar 2017 11:17:33 +0200
From:   Benjamin Gaignard <benjamin.gaignard@...aro.org>
To:     Jose Abreu <Jose.Abreu@...opsys.com>
Cc:     "linux-media@...r.kernel.org" <linux-media@...r.kernel.org>,
        hans.verkuil@...co.com, Mauro Carvalho Chehab <mchehab@...nel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/8] [media] staging: st-cec: Use cec_get_drvdata()

2017-03-24 17:47 GMT+01:00 Jose Abreu <Jose.Abreu@...opsys.com>:
> Use helper function to get driver private data from CEC
> adapter.

That looks good for me but does it make sense to merge that now ? or
should we wait until
cec drivers as move out of staging ?
Hans what is your view on that ?

>
> Signed-off-by: Jose Abreu <joabreu@...opsys.com>
> Cc: Benjamin Gaignard <benjamin.gaignard@...aro.org>
> ---
>  drivers/staging/media/st-cec/stih-cec.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/staging/media/st-cec/stih-cec.c b/drivers/staging/media/st-cec/stih-cec.c
> index 3c25638..521206d 100644
> --- a/drivers/staging/media/st-cec/stih-cec.c
> +++ b/drivers/staging/media/st-cec/stih-cec.c
> @@ -133,7 +133,7 @@ struct stih_cec {
>
>  static int stih_cec_adap_enable(struct cec_adapter *adap, bool enable)
>  {
> -       struct stih_cec *cec = adap->priv;
> +       struct stih_cec *cec = cec_get_drvdata(adap);
>
>         if (enable) {
>                 /* The doc says (input TCLK_PERIOD * CEC_CLK_DIV) = 0.1ms */
> @@ -189,7 +189,7 @@ static int stih_cec_adap_enable(struct cec_adapter *adap, bool enable)
>
>  static int stih_cec_adap_log_addr(struct cec_adapter *adap, u8 logical_addr)
>  {
> -       struct stih_cec *cec = adap->priv;
> +       struct stih_cec *cec = cec_get_drvdata(adap);
>         u32 reg = readl(cec->regs + CEC_ADDR_TABLE);
>
>         reg |= 1 << logical_addr;
> @@ -205,7 +205,7 @@ static int stih_cec_adap_log_addr(struct cec_adapter *adap, u8 logical_addr)
>  static int stih_cec_adap_transmit(struct cec_adapter *adap, u8 attempts,
>                                   u32 signal_free_time, struct cec_msg *msg)
>  {
> -       struct stih_cec *cec = adap->priv;
> +       struct stih_cec *cec = cec_get_drvdata(adap);
>         int i;
>
>         /* Copy message into registers */
> --
> 1.9.1
>
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ