[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87d0egjzxk.fsf@belgarion.home>
Date: Mon, 28 Oct 2019 22:57:43 +0100
From: Robert Jarzmik <robert.jarzmik@...e.fr>
To: Arnd Bergmann <arnd@...db.de>
Cc: Daniel Mack <daniel@...que.org>,
Haojian Zhuang <haojian.zhuang@...il.com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
Linus Walleij <linus.walleij@...aro.org>,
Dominik Brodowski <linux@...inikbrodowski.net>
Subject: Re: [PATCH 33/46] ARM: pxa: pcmcia: move smemc configuration back to arch
Arnd Bergmann <arnd@...db.de> writes:
> Rather than poking at the smemc registers directly from the
> pcmcia/pxa2xx_base driver, move those bits into machine file
> to have a cleaner interface.
>
> Cc: Dominik Brodowski <linux@...inikbrodowski.net>
> Signed-off-by: Arnd Bergmann <arnd@...db.de>
> -static int pxa2xx_pcmcia_set_mcxx(struct soc_pcmcia_socket *skt, unsigned int clk)
> +static int pxa2xx_pcmcia_set_timing(struct soc_pcmcia_socket *skt)
> {
> + unsigned long clk = clk_get_rate(skt->clk) / 1000;
> struct soc_pcmcia_timing timing;
> int sock = skt->nr;
>
> soc_common_pcmcia_get_timing(skt, &timing);
>
> - pxa2xx_pcmcia_set_mcmem(sock, timing.mem, clk);
> - pxa2xx_pcmcia_set_mcatt(sock, timing.attr, clk);
> - pxa2xx_pcmcia_set_mcio(sock, timing.io, clk);
> + pxa_smemc_set_pcmcia_timing(sock,
> + pxa2xx_pcmcia_mcmem(sock, timing.mem, clk),
> + pxa2xx_pcmcia_mcatt(sock, timing.attr, clk),
> + pxa2xx_pcmcia_mcio(sock, timing.io, clk));
>
> return 0;
> }
>
> -static int pxa2xx_pcmcia_set_timing(struct soc_pcmcia_socket *skt)
> -{
> - unsigned long clk = clk_get_rate(skt->clk);
> - return pxa2xx_pcmcia_set_mcxx(skt, clk / 10000);
That curious, because you divide here by 10^4, while in the old
pxa2xx_pcmcia_set_mcxx() that was 10^3 ... is that a fix I don't see ?
Cheers.
--
Robert
Powered by blists - more mailing lists