[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <VI1PR0401MB2638F63D1552B2C9689568FD8D9D0@VI1PR0401MB2638.eurprd04.prod.outlook.com>
Date: Thu, 15 Dec 2016 22:43:29 +0000
From: Stuart Yoder <stuart.yoder@....com>
To: Laurentiu Tudor <laurentiu.tudor@....com>,
"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>
CC: "devel@...verdev.osuosl.org" <devel@...verdev.osuosl.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"agraf@...e.de" <agraf@...e.de>, "arnd@...db.de" <arnd@...db.de>,
Leo Li <leoyang.li@....com>,
Ioana Ciornei <ioana.ciornei@....com>,
"Catalin Horghidan" <catalin.horghidan@....com>,
Ruxandra Ioana Radulescu <ruxandra.radulescu@....com>,
Roy Pledge <roy.pledge@....com>,
Haiying Wang <haiying.wang@....com>
Subject: RE: [PATCH v3 7/9] bus: fsl-mc: dpio: add the DPAA2 DPIO service
interface
> > +struct dpaa2_io *dpaa2_io_create(const struct dpaa2_io_desc *desc)
> > +{
> > + struct dpaa2_io *obj = kmalloc(sizeof(*obj), GFP_KERNEL);
> > +
> > + if (!obj)
> > + return NULL;
> > +
> > + /* check if CPU is out of range (-1 means any cpu) */
> > + if (desc->cpu >= num_possible_cpus())
>
> We leak 'obj' on this error path.
Will fix.
> > +
> > +/**
> > + * dpaa2_io_service_rearm() - Rearm the notification for the given DPIO service.
> > + * @service: the given DPIO service.
>
> s/@...vice/@d/
Will fix.
> > +/**
> > + * dpaa2_io_store_next() - Determine when the next dequeue result is available.
> > + * @s: the dpaa2_io_store object.
> > + * @is_last: indicate whether this is the last frame in the pull command.
> > + *
> > + * When an object driver performs dequeues to a dpaa2_io_store, this function
> > + * can be used to determine when the next frame result is available. Once
> > + * this function returns non-NULL, a subsequent call to it will try to find
> > + * the next dequeue result.
> > + *
> > + * Note that if a pull-dequeue has a NULL result because the target FQ/channel
> > + * was empty, then this function will also return NULL (rather than expecting
> > + * the caller to always check for this. As such, "is_last" can be used to
> > + * differentiate between "end-of-empty-dequeue" and "still-waiting".
> > + *
> > + * Return dequeue result for a valid dequeue result, or NULL for empty dequeue.
> > + */
> > +struct dpaa2_dq *dpaa2_io_store_next(struct dpaa2_io_store *s, int *is_last)
>
> "bool *is_last"?
Same comment here as on the other patch...let's get Roy's input on this
and make it a TODO if deemed a good idea.
Thanks,
Stuartt
Powered by blists - more mailing lists