Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1550572 > unrolled thread

Re: [PATCH 7/7] misc: intel-ish-client: add intel ishtp clients driver

Started byJiri Kosina <jikos@kernel.org>
First post2017-01-04 10:40 +0100
Last post2017-01-04 14:10 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH 7/7] misc: intel-ish-client: add intel ishtp clients  driver Jiri Kosina <jikos@kernel.org> - 2017-01-04 10:40 +0100
    Re: [PATCH 7/7] misc: intel-ish-client: add intel ishtp clients  driver "gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org> - 2017-01-04 14:10 +0100

#1550572 — Re: [PATCH 7/7] misc: intel-ish-client: add intel ishtp clients driver

FromJiri Kosina <jikos@kernel.org>
Date2017-01-04 10:40 +0100
SubjectRe: [PATCH 7/7] misc: intel-ish-client: add intel ishtp clients driver
Message-ID<sVQd3-2M8-13@gated-at.bofh.it>
On Wed, 4 Jan 2017, Xu, Even wrote:

> > [ ... snip ... ]
> > > 
> > > +static ssize_t ishtp_cl_write(struct file *file, const char __user
> > > *ubuf,
> > > +	size_t length, loff_t *offset)
> > > +{
> > > +	struct ishtp_cl_miscdev *ishtp_cl_misc = file-
> > > >private_data;
> > > +	struct ishtp_cl *cl;
> > > +	void *write_buf;
> > > +	struct ishtp_device *dev;
> > > +	int ret;
> > > +
> > > +	/* Non-blocking semantics are not supported */
> > > +	if (file->f_flags & O_NONBLOCK) {
> > > +		ret = -EINVAL;
> > > +		goto out_unlock;
> > When taking the error path here you'd try to unlockĀ 
> > ishtp_cl_misc->cl_mutex before actually acquiring it.
> > 
> 
> Thanks for your comments, Jiri, I update my patch below:

Greg, how would you like to handle this (after you're done with reviewing 
it of course), given that this driver depends on the preceeding 6 patches 
to intel-ish-hid driver?

Thanks,

-- 
Jiri Kosina
SUSE Labs

[toc] | [next] | [standalone]


#1550761

From"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>
Date2017-01-04 14:10 +0100
Message-ID<sVTui-55P-53@gated-at.bofh.it>
In reply to#1550572
On Wed, Jan 04, 2017 at 10:36:18AM +0100, Jiri Kosina wrote:
> On Wed, 4 Jan 2017, Xu, Even wrote:
> 
> > > [ ... snip ... ]
> > > > 
> > > > +static ssize_t ishtp_cl_write(struct file *file, const char __user
> > > > *ubuf,
> > > > +	size_t length, loff_t *offset)
> > > > +{
> > > > +	struct ishtp_cl_miscdev *ishtp_cl_misc = file-
> > > > >private_data;
> > > > +	struct ishtp_cl *cl;
> > > > +	void *write_buf;
> > > > +	struct ishtp_device *dev;
> > > > +	int ret;
> > > > +
> > > > +	/* Non-blocking semantics are not supported */
> > > > +	if (file->f_flags & O_NONBLOCK) {
> > > > +		ret = -EINVAL;
> > > > +		goto out_unlock;
> > > When taking the error path here you'd try to unlockĀ 
> > > ishtp_cl_misc->cl_mutex before actually acquiring it.
> > > 
> > 
> > Thanks for your comments, Jiri, I update my patch below:
> 
> Greg, how would you like to handle this (after you're done with reviewing 
> it of course), given that this driver depends on the preceeding 6 patches 
> to intel-ish-hid driver?

Let me go review it now, but if it's ok, I have no problem taking it in
my tree, or if you want to take it through yours, that's fine with me,
which ever is easiest for you.

thanks,

greg k-h

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web