linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* linux-4.14-rc3/arch/powerpc/perf/imc-pmu.c:599: pointless test ?
@ 2017-10-06 18:54 David Binderman
  2017-10-09  5:01 ` Michael Ellerman
  0 siblings, 1 reply; 3+ messages in thread
From: David Binderman @ 2017-10-06 18:54 UTC (permalink / raw)
  To: benh@kernel.crashing.org, paulus@samba.org, mpe@ellerman.id.au,
	linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org

Hello there,

linux-4.14-rc3/arch/powerpc/perf/imc-pmu.c:599]: (style) Unsigned variable =
'ncpu' can't be negative so it is unnecessary to test it.

Source code is

    if (ncpu >=3D 0 && ncpu < nr_cpu_ids) {

but

    unsigned int ncpu, core_id;

Suggest remove test.

Regards

David Binderman=

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-10-09 11:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-06 18:54 linux-4.14-rc3/arch/powerpc/perf/imc-pmu.c:599: pointless test ? David Binderman
2017-10-09  5:01 ` Michael Ellerman
2017-10-09 11:38   ` Anju T Sudhakar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).