lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 9 Jun 2010 17:04:09 +0530
From:	"Vijay R. Iyengar" <Vijay.Iyengar@...tcummins.com>
To:	"jic23@...mes.cam.ac.uk" <jic23@...mes.cam.ac.uk>
CC:	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"sameo@...ux.intel.com" <sameo@...ux.intel.com>,
	David Dajun Chen <Dajun.Chen@...semi.com>,
	"Ashish P. Chavan" <Ashish.Chavan@...tcummins.com>,
	Nitin Shah <Nitin.Shah@...tcummins.com>
Subject: RE: [PATCH] MFD of DA9052 Linux device drivers (1/9)

 
> -----Original Message-----
> From: J.I. Cameron [mailto:jic23@...mes.cam.ac.uk] On Behalf 
> Of Jonathan
> Cameron
> Sent: 19 May 2010 12:22
> To: David Dajun Chen
> Cc: linux-kernel@...r.kernel.org; sameo@...ux.intel.com
> Subject: Re: [PATCH] MFD of DA9052 Linux device drivers (1/9)
> 
> Hi David,
> 
> Below is an initial review. Please take a look at more code 
> for similar
> drivers
> in the various subsystems as it will give you an idea how how much of
> this should
> be done.
> 
> I've run out of time, so I'm afraid I didn't get quite to the 
> bottom of
> this patch.
> Still plenty of stuff still to do in the bit I did look at!
> 
> Jonathan
> > +
> > +/**
> > + * da9052_eh_unregister_nb:	Function to de-register 
> a notifier block
> > + *
> > + * Caller must not pass any non-existing notifier block or 
> notifiler
> block
> > + * that has already been de-registered. Its caller's responsibility
> to 
> > + * allocate/deallocate memory associated with notifier 
> block. EH will
> only 
> > + * Link/De-Link passed notifier blocks.
> > + *
> > + * @param nb	: Notifier block to unregister
> > + * @return s32	: Status of unregistration
> > + */
> > +s32 da9052_eh_unregister_nb(da9052_eh_nb* nb){
> > +	
> > +	if(nb == NULL)
> > +		return (INVALID_NB);
> > +	
> > +	DA9052_DEBUG("%s() called for event %d \n", __FUNCTION__,
> nb->eve_type);
> > +	
> > +	/* Acqurie nb array lock */
> > +	if(down_interruptible(&eh_info.eve_nb_array_lock))
> > +		return (FAILURE);
> > +	
> > +	/* Remove passed NB from list */
> > +	list_del_init(&(nb->nb_list));
> > +	
> > +	/* Release NB array lock */
> > +	up(&eh_info.eve_nb_array_lock);
> > +	
> > +	return (SUCCESS);
> > +}
> > +
> 
> These are looking pretyt touch screen specific.  What are 
> they doing in
> this patch?

We have designed the EH (interrupt handler driver) and the TSI (touch screen driver) in a manner that the EH reads raw co-ordinates from the touch control registers of the DA9052 hardware in response to sampling ready interrupt requests and stores them in a FIFO for TSI further processing.

We are implementing a common Event handler module for processing all the interrupt events from the DA9052 devices like battery, regulator, RTC etc. Fetching the TSI samples on touch events by EH rather than notifying the TSI driver through a call-back routine helps us to get a good amount of filtered touch samples from the TSI driver. 

Hence we intend to keep the TSI raw co-ordinate reading in the event handling module, which is a part of the MFD driver.

> > +/**
> > + * da9052_tsi_start_sampling:	Called by TSI driver to indicate
> start of data
> > + * sampling
> > + * @param void
> > + * @return int status
> > + */
> > +s32 da9052_tsi_start_sampling(void){
> > +	
> > +	/* This request is only valid when we are waiting for one */
> > +	if(tsi_info.tsi_state == WAIT_FOR_SAMPLING){
> > +		DA9052_DEBUG("__%s__ \n", __FUNCTION__);
> > +		tsi_info.tsi_state =  SAMPLING_ACTIVE;
> > +		return (SUCCESS);
> > +	}
> > +	else{
> > +		DA9052_DEBUG("Invalid request for
> da9052_tsi_start_sampling() \n");
> > +		return (FAILURE);
> > +	}	
> > +}
> > +
> > +/**
> > + * da9052_tsi_stop_sampling:	Called by TSI driver to 
> indicate end of
> data
> > + * sampling
> > + * @param void
> > + * @return int status
> > + */
> > +s32 da9052_tsi_stop_sampling(void){
> > +	
> > +	/* Irrespective of current state, move to initial state */
> > +	DA9052_DEBUG("__%s__ \n", __FUNCTION__);
> > +	tsi_info.tsi_state =  WAIT_FOR_PEN_DOWN;
> > +
> > +	return (SUCCESS);
> > +}

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ