Re: [PATCH v3] Input: synaptics-rmi4 - convert irq distribution to irq_domain

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 25, 2018 at 12:17:33PM -0700, Dmitry Torokhov wrote:
> On Tue, Mar 27, 2018 at 10:32:25PM +0100, Nick Dyer wrote:
> > Convert the RMI driver to use the standard mechanism for
> > distributing IRQs to the various functions.
> > 
> > Tested on:
> > * S7300 (F11, F34, F54)
> > * S7817 (F12, F34, F54)
> > 
> > [v2: mark interrupts as threaded, move irq init code]
> > [v3: use fwnode api, handle teardown as per dtor comments]
> > 
> > Signed-off-by: Nick Dyer <nick@xxxxxxxxxxxxx>
> > Acked-by: Christopher Heiny <cheiny@xxxxxxxxxxxxx>
> 
> I was about to apply this, but I was getting some compile warnings:
> 
> >  
> >  static void rmi_f11_finger_handler(struct f11_data *f11,
> >  				   struct rmi_2d_sensor *sensor,
> > -				   unsigned long *irq_bits, int num_irq_regs,
> > -				   int size)
> > +				   int num_irq_regs, int size)
> 
> I do not see where we are using num_irq_regs...

Ack. removed.

> > -	if (rel_bits) {
> > +	if (sensor->report_rel) {
> >  		if ((abs_size + sensor->nbr_fingers * RMI_F11_REL_BYTES) > size)
> >  			rel_fingers = (size - abs_size) / RMI_F11_REL_BYTES;
> >  		else
> > @@ -616,7 +610,7 @@ static void rmi_f11_finger_handler(struct f11_data *f11,
> >  			rmi_f11_rel_pos_report(f11, i);
> >  	}
> >  
> > -	if (abs_bits) {
> > +	if (sensor->report_abs) {
> 
> I do not see the reason why we split reporting abs like this, and that
> is what causing "maybe uninitialized" warning. Please move it all into
> single branch of "if (sensor->report_abs)" (but still keeping the "2
> pass" approach of first parsing the reports, assigning slots if needed,
> and then sending corresponding events).

Yes. I think it makes more sense this way.

I'll post an updated patch in reply to this.

Nick
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux