lkml.org 
[lkml]   [2019]   [Oct]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH 33/46] ARM: pxa: pcmcia: move smemc configuration back to arch
    Date
    Arnd Bergmann <arnd@arndb.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@dominikbrodowski.net>
    > Signed-off-by: Arnd Bergmann <arnd@arndb.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

    \
     
     \ /
      Last update: 2019-10-28 22:58    [W:3.158 / U:0.044 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site