On Thu, Sep 17, 2015 at 12:01 AM, Jani Nikula jani.nikula@linux.intel.com wrote:
On Wed, 16 Sep 2015, Ville Syrjälä ville.syrjala@linux.intel.com wrote:
On Wed, Sep 16, 2015 at 01:09:54PM -0700, Daniel Vetter wrote:
On Tue, Sep 15, 2015 at 10:03:09AM -0700, Rafael Antognolli wrote:
On Tue, Sep 15, 2015 at 07:46:55PM +0300, Ville Syrjälä wrote:
On Tue, Sep 15, 2015 at 07:41:06PM +0300, Ville Syrjälä wrote:
On Tue, Sep 15, 2015 at 09:34:15AM -0700, Rafael Antognolli wrote: > On Tue, Sep 15, 2015 at 10:35:19AM +0300, Ville Syrjälä wrote: > > On Mon, Sep 14, 2015 at 04:12:29PM -0700, Rafael Antognolli wrote: > > > This is a tentative implementation of a module that allows reading/writing > > > arbitrary dpcd registers, following the suggestion from Daniel Vetter. It > > > assumes the drm aux helpers were used by the driver. > > > > > > I tried to follow the i2c-dev implementation as close as possible, but the only > > > operations that are provided on the dev node are two different ioctl's, one for > > > reading a register and another one for writing it. > > > > Why would you use ioctls instead of normal read/write syscalls? > > > > For writing, that should work fine, I can easily change that if you > prefer. > > For reading, one has to first tell which register address is going to be > read.
seek()
Sorry typo. Make that lseek().
Oh, nice, I'll update the patch with this and remove the notifier stuff, thanks!
Well there's also other modes like i2c over aux, and that would be easier to support with an ioctl in a uniform way. So not sure how much value there is in reusing read/write for i2c ...
We already have i2c-dev for i2c. So not sure what you're after here.
Yeah, definitely don't reinvent the wheel for this.
Of course I didn't mean to reinvent the i2c-dev wheel, but just expose the underlying low-level dp aux ops to do i2c transaction - that might be useful for hacking around to figure out some of the recent i2c changes we've done. Otoh we could add such a raw mode later on as an ioctl, for plain dpcd reads/writes read/write/lseek seems indeed a good fit. -Daniel