Florian Westphal <f...@strlen.de> wrote:
> Ander Juaristi <a...@juaristi.eus> wrote:
> > +++ b/net/netfilter/nft_meta.c
> > @@ -28,6 +28,27 @@
> >  
> >  static DEFINE_PER_CPU(struct rnd_state, nft_prandom_state);
> >  
> > +static u8 nft_meta_weekday(unsigned long secs)
> > +{
> > +   u8 wday;
> > +   unsigned int dse;
> > +
> > +   secs -= 60 * sys_tz.tz_minuteswest;
> > +   dse = secs / 86400;
> 
> This will probably fail to compile (link) on 32bit arches.
> You need to use do_div() here.

Scratch that, this will work fine (unsigned long is not a 64 bit
type in that case).

Reply via email to