Re: [PATCH] staging: media: atomisp: move constant to the right side of comparisons
Andy Shevchenko <[email protected]> Fri, 7 Aug 2026 02:06:23 +0300
| Newsgroups | org.kernel.vger.linux-media,dev.linux.lists.linux-staging,org.kernel.vger.linux-kernel |
|---|---|
| Organization | Intel Finland Oy - BIC 0357606-4 - c/o Alberga Business Park, 6 krs, Bertel Jungin Aukio 5, 02600 Espoo |
| Message-ID | <[email protected]> |
On Thu, Jul 23, 2026 at 12:50:20PM -0300, Sergei Stepanenkov wrote: > Fix all checkpatch warning occurences > "WARNING: Comparisons should place the constant on the right side of > the test" in folder drivers/staging/media/atomisp/pci > > Signed-off-by: Sergei Stepanenkov <[email protected]> > --- > Hey, this is my first patch, I appreciate any feedback, thanks! Right. Please, read lore.kernel.org linux-media@ archives against this driver to understand what to do with this patch. Also, if you are in a group that is mentored, tell to the mentors to stop looking into this driver by a newbie. This driver has much more urgent tasks to do and it's not trivial, it also requires a real HW to be at hand to test. ... > - if (0 != ia_css_pipe_get_info(asd->stream_env[stream_index] > - .pipes[pipe_index], &info)) { > + if (ia_css_pipe_get_info(asd->stream_env[stream_index] > + .pipes[pipe_index], &info) != 0) { The style is still wrong. > dev_dbg(isp->dev, "ia_css_pipe_get_info FAILED"); > return -EINVAL; > } The above most likely already or should return a Linux error code in which case the whole thing should be refactored, ret = ia_css_pipe_get_info(asd->stream_env[stream_index].pipes[pipe_index], &info); if (ret) dev_dbg(isp->dev, "ia_css_pipe_get_info FAILED"); return ret; } -- With Best Regards, Andy Shevchenko