From: Jorge Ramirez Date: Mon, 8 May 2017 11:30:45 +0200 Subject: [U-Boot] [PATCHv2 5/5] ARM64: poplar: hi3798cv200: u-boot support for Poplar 96Boards In-Reply-To: <1494233801-21588-5-git-send-email-jorge.ramirez-ortiz@linaro.org> References: <1494233801-21588-1-git-send-email-jorge.ramirez-ortiz@linaro.org> <1494233801-21588-5-git-send-email-jorge.ramirez-ortiz@linaro.org> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 05/08/2017 10:56 AM, Jorge Ramirez-Ortiz wrote: > +static inline void usb2_phy_write(u32 val) > +{ > + writel(val, PERI_CTRL_USB0); > + clrsetbits_le32(PERI_CTRL_USB0, BIT(21), BIT(20) | BIT(22)); Just noticed that the write below is unnecessary will remove this inline function and fix it on v3 > + writel(val, PERI_CTRL_USB0); > + > + udelay(20); > +} > + > +static void usb2_phy_config(void) > +{ > + const u32 config[] = { > + /* close EOP pre-emphasis. open data pre-emphasis */ > + 0xa1001c, > + /* Rcomp = 150mW, increase DC level */ > + 0xa00607, > + /* keep Rcomp working */ > + 0xa10700, > + /* Icomp = 212mW, increase current drive */ > + 0xa00aab, > + /* EMI fix: rx_active not stay 1 when error packets received */ > + 0xa11140, > + /* Comp mode select */ > + 0xa11041, > + /* adjust eye diagram */ > + 0xa0098c, > + /* adjust eye diagram */ > + 0xa10a0a, > + }; > + int i; > + > + for (i = 0; i < ARRAY_SIZE(config); i++) > +