From mboxrd@z Thu Jan 1 00:00:00 1970 From: Heiko Schocher Date: Tue, 15 Jul 2014 11:27:37 +0200 Subject: [U-Boot] [PATCH v2 3/5] i.MX6: define struct pwm_regs and PWMCR_* defines In-Reply-To: <53C4ED44.1030604@denx.de> References: <1405138221-4721-1-git-send-email-hs@denx.de> <1405138221-4721-4-git-send-email-hs@denx.de> <53C4E272.8010409@denx.de> <53C4EBE4.80602@denx.de> <53C4ED44.1030604@denx.de> Message-ID: <53C4F409.3080901@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 Hello Stefano, Am 15.07.2014 10:58, schrieb Stefano Babic: > Hi Heiko, > > On 15/07/2014 10:52, Heiko Schocher wrote: > >>> I see. What do you mind to add a little effort and move the setup of the >>> PWM from the aristaneos board to a PWM driver ? I see there is not (yet) >>> such a driver, but why not ? >> >> Yes, I can do that ... Hmm, where do you think is a good place for this >> driver? >> > > IMHO you can create a drivers/pwm directory and add a pwm-imx.c driver. > This reflects the same we have in kernel. Yes, that was also my first thought, but we have a API for this in include/pwm.h but no drivers/pwm ... so I searched pwm_init and found: pollux:u-boot hs [20140715] $ grep -lr pwm_init . ./include/.pwm.h.swp ./include/pwm.h ./arch/arm/include/asm/arch-tegra20/pwm.h ./arch/arm/cpu/armv7/s5p-common/pwm.c ./arch/arm/cpu/armv7/s5p-common/timer.c ./arch/arm/cpu/armv7/tegra20/pwm.c ./board/nvidia/common/board.c pollux:u-boot hs [20140715] $ I think, it would better to add a "arch/arm/cpu/armv7/mx6/pwm.c" Would this be ok? bye, Heiko -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany