Re: [PATCH] blk-iocost: don't make all constants unsigned long long

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

 



On Wed, Jan 04, 2023 at 12:15:06PM -1000, Tejun Heo wrote:
> On Thu, Dec 22, 2022 at 02:58:55PM +0100, Michal Koutný wrote:
> > On Tue, Dec 20, 2022 at 09:18:19PM +0100, Yann Droneaud <ydroneaud@xxxxxxxxxx> wrote:
> > > +enum {
> > >  	/* switch iff the conditions are met for longer than this */
> > >  	AUTOP_CYCLE_NSEC	= 10LLU * NSEC_PER_SEC,
> > > +};
> > 
> > This looks gratuitous.
> > 
> > What about indivudial #defines with typed literals instead of the "lazy
> > splitting"?
> 
> enums are so much better for debugging and tracing. This is a gcc caused
> problem where there's no other way to generate the same code between two gcc
> versions without splitting the enum definitions. I'm kinda baffled that this
> is what they chose to do but can't think of a better way to work around it.

I thought this was the other patch addressing this issue. The proposed patch
is rather painful to look at. The other one splits it into two groups.

Thanks.

-- 
tejun



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux