Re: [PATCH v2 3/5] media: mali-c55: Add Mali-C55 ISP driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jacopo,

On Wed, Feb 28, 2024 at 01:50:14PM +0100, Jacopo Mondi wrote:
> > > +const struct mali_c55_fmt *mali_c55_cap_fmt_next(const struct mali_c55_fmt *fmt,
> > > +						 bool allow_raw, bool unique)
> > > +{
> > > +	if (!fmt)
> > > +		fmt = &mali_c55_fmts[0];
> > > +	else
> > > +		++fmt;
> >
> > fmt++, please.
> >
> 
> Can I ask why ? (here and in the next occurrences you have reported)

It's much, much more common and using that form makes the code easier to
read. The rest of the driver primarily uses variable++, too, AFAIR.

So you should use ++variable only when you need it.

-- 
Sakari Ailus




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux