[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1383162100.9435.39.camel@joe-AO722>
Date: Wed, 30 Oct 2013 12:41:40 -0700
From: Joe Perches <joe@...ches.com>
To: Peter Hüwe <PeterHuewe@....de>
Cc: Jason Gunthorpe <jgunthorpe@...idianresearch.com>,
Ashley Lai <ashley@...leylai.com>,
Rajiv Andrade <mail@...jiv.net>,
Marcel Selhorst <tpmdd@...horst.net>,
tpmdd-devel@...ts.sourceforge.net, linux-kernel@...r.kernel.org,
Xiaoyan Zhang <xiaoyan.zhang@...el.com>,
Gang Wei <gang.wei@...el.com>, stable@...r.kernel.org
Subject: Re: [PATCH 1/2] tpm/tpm_ppi: Do not compare strcmp(a,b) == -1
On Wed, 2013-10-30 at 20:35 +0100, Peter Hüwe wrote:
> Hi Joe, Jason
Hi Peter.
> > lib/string.c:strcmp returns only -1,0,1
> > so that's what the arch versions should do too.
> > However, arch implementations do vary...
[]
> I did not pay attention to where cscope did send me
> - it was arch/x86/boot/string.c which implements it as
>
> while (*s1 || *s2) {
> delta = *s2 - *s1;
> if (delta)
> return delta;
> s1++;
> s2++;
> }
>
> Although I know that this is not used here,
> it differs from the version in lib. (Maybe worth changing?)
The arch/... assembly versions don't always
return -1, 0, 1 so I don't think it's worth
it to change all of those.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists