RE: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-18 Thread li.xi...@freescale.com
> On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: > > On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: > > > I fail to see how that would eliminate the problem with the types. > > > That said I don't actually see sparse complaining about any type > mismatches. > > >

RE: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-18 Thread li.xi...@freescale.com
On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: I fail to see how that would eliminate the problem with the types. That said I don't actually see sparse complaining about any type mismatches. That's probably

RE: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread li.xi...@freescale.com
> On Tue, Dec 17, 2013 at 01:00:10PM +0100, Tomasz Figa wrote: > > On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: > > > On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: > > > > On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: > > > > > +static

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 01:04:35PM +, Russell King - ARM Linux wrote: > On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: > > On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: > > > I fail to see how that would eliminate the problem with the types. That > > > said I

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 12:58:32PM +, Russell King - ARM Linux wrote: > On Tue, Dec 17, 2013 at 01:24:33PM +0100, Thierry Reding wrote: > > On Tue, Dec 17, 2013 at 11:51:36AM +, Russell King - ARM Linux wrote: > > > Same comments here - what memory operations is the wmb() trying to > > >

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Tomasz Figa
On Tuesday 17 of December 2013 13:04:35 Russell King - ARM Linux wrote: > On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: > > On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: > > > I fail to see how that would eliminate the problem with the types. That > > > said I don't

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Russell King - ARM Linux
On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: > On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: > > I fail to see how that would eliminate the problem with the types. That > > said I don't actually see sparse complaining about any type mismatches. > > That's probably

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Russell King - ARM Linux
On Tue, Dec 17, 2013 at 01:24:33PM +0100, Thierry Reding wrote: > On Tue, Dec 17, 2013 at 11:51:36AM +, Russell King - ARM Linux wrote: > > Same comments here - what memory operations is the wmb() trying to > > serialise? Does this PWM driver somehow end up doing DMA? > > Not that I can see.

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Tomasz Figa
On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: > On Tue, Dec 17, 2013 at 01:00:10PM +0100, Tomasz Figa wrote: > > On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: > > > On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: > > > > On Fri, Dec 13,

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 01:00:10PM +0100, Tomasz Figa wrote: > On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: > > On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: > > > On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: > > > > +static inline u32

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 11:51:36AM +, Russell King - ARM Linux wrote: > On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: > > On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: > > > +static inline u32 fsl_pwm_readl(struct fsl_pwm_chip *fpc, > > > + const void

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Tomasz Figa
On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: > On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: > > On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: > > > +static inline u32 fsl_pwm_readl(struct fsl_pwm_chip *fpc, > > > + const void

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Russell King - ARM Linux
On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: > On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: > > +static inline u32 fsl_pwm_readl(struct fsl_pwm_chip *fpc, > > + const void __iomem *addr) > > +{ > > + u32 val; > > + > > + val = __raw_readl(addr); > > +

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: [...] > diff --git a/drivers/pwm/Makefile b/drivers/pwm/Makefile > index 8b754e4..9029a12 100644 > --- a/drivers/pwm/Makefile > +++ b/drivers/pwm/Makefile > @@ -5,6 +5,7 @@ obj-$(CONFIG_PWM_ATMEL_TCB) += pwm-atmel-tcb.o >

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: [...] diff --git a/drivers/pwm/Makefile b/drivers/pwm/Makefile index 8b754e4..9029a12 100644 --- a/drivers/pwm/Makefile +++ b/drivers/pwm/Makefile @@ -5,6 +5,7 @@ obj-$(CONFIG_PWM_ATMEL_TCB) += pwm-atmel-tcb.o

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Russell King - ARM Linux
On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: +static inline u32 fsl_pwm_readl(struct fsl_pwm_chip *fpc, + const void __iomem *addr) +{ + u32 val; + + val = __raw_readl(addr); + + if

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Tomasz Figa
On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: +static inline u32 fsl_pwm_readl(struct fsl_pwm_chip *fpc, + const void __iomem *addr)

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 11:51:36AM +, Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: +static inline u32 fsl_pwm_readl(struct fsl_pwm_chip *fpc, + const void __iomem

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 01:00:10PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: +static inline u32

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Tomasz Figa
On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: On Tue, Dec 17, 2013 at 01:00:10PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: On Fri, Dec 13, 2013 at

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Russell King - ARM Linux
On Tue, Dec 17, 2013 at 01:24:33PM +0100, Thierry Reding wrote: On Tue, Dec 17, 2013 at 11:51:36AM +, Russell King - ARM Linux wrote: Same comments here - what memory operations is the wmb() trying to serialise? Does this PWM driver somehow end up doing DMA? Not that I can see. But if

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Russell King - ARM Linux
On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: I fail to see how that would eliminate the problem with the types. That said I don't actually see sparse complaining about any type mismatches. That's probably because

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Tomasz Figa
On Tuesday 17 of December 2013 13:04:35 Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: I fail to see how that would eliminate the problem with the types. That said I don't actually

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 12:58:32PM +, Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 01:24:33PM +0100, Thierry Reding wrote: On Tue, Dec 17, 2013 at 11:51:36AM +, Russell King - ARM Linux wrote: Same comments here - what memory operations is the wmb() trying to serialise?

Re: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread Thierry Reding
On Tue, Dec 17, 2013 at 01:04:35PM +, Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 01:54:35PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 13:45:06 Thierry Reding wrote: I fail to see how that would eliminate the problem with the types. That said I don't

RE: [PATCHv7 1/4] pwm: Add Freescale FTM PWM driver support

2013-12-17 Thread li.xi...@freescale.com
On Tue, Dec 17, 2013 at 01:00:10PM +0100, Tomasz Figa wrote: On Tuesday 17 of December 2013 11:51:36 Russell King - ARM Linux wrote: On Tue, Dec 17, 2013 at 12:10:22PM +0100, Thierry Reding wrote: On Fri, Dec 13, 2013 at 04:57:04PM +0800, Xiubo Li wrote: +static inline u32