lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Mon, 28 Jan 2019 20:45:46 +0000 From: Sudip Mukherjee <sudipm.mukherjee@...il.com> To: qiaochong <qiaochong@...ngson.cn> Cc: linux-kernel <linux-kernel@...r.kernel.org> Subject: Re: [PATCH] parport_pc: fix find_superio io compare code, should use equal test. Hi QiaoChong, On Tue, Jan 22, 2019 at 3:04 PM qiaochong <qiaochong@...ngson.cn> wrote: > > From: QiaoChong <qiaochong@...ngson.cn> > > git blame drivers/parport/parport_pc.c > > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1376) static struct superio_struct *find_superio(struct parport *p) > ^1da177e4c3f4 (Linus Torvalds 2005-04-16 15:20:36 -0700 1377) { > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1378) int i; > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1379) for (i = 0; i < NR_SUPERIOS; i++) > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1380) if (superios[i].io != p->base) > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1381) return &superios[i]; > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1382) return NULL; > 181bf1e815a2a (Alan Cox 2009-06-11 13:08:10 +0100 1383) } > 73e0d48b8c28f (Michael Buesch 2009-06-11 13:06:31 +0100 1384) > > git log -1 -p 181bf1e815a2a > > -static int get_superio_dma(struct parport *p) > +static struct superio_struct *find_superio(struct parport *p) > { > - int i = 0; > + int i; > + for (i = 0; i < NR_SUPERIOS; i++) > + if (superios[i].io != p->base) > + return &superios[i]; > + return NULL; > +} > > - while ((i < NR_SUPERIOS) && (superios[i].io != p->base)) > - i++; > - if (i != NR_SUPERIOS) > - return superios[i].dma; > > the code before 181bf1e815a2a also mean superio[i].io == p->base, fixup it. So, this means the Super-IO chips irq and dma has not worked since 2009. :( Can you please resend this with a proper commit message.. -- Regards Sudip
Powered by blists - more mailing lists