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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1273667099.23818.86.camel@e102109-lin.cambridge.arm.com>
Date:	Wed, 12 May 2010 13:24:59 +0100
From:	Catalin Marinas <catalin.marinas@....com>
To:	Sebastian Andrzej Siewior <sebastian@...akpoint.cc>
Cc:	Robert Hancock <hancockrwd@...il.com>,
	saeed bishara <saeed.bishara@...il.com>,
	linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>,
	DE/ATA development list <linux-ide@...r.kernel.org>,
	lkml <linux-kernel@...r.kernel.org>,
	Jeff Garzik <jeff@...zik.org>
Subject: Re: [BUG] bug when enabling VM DEBUG

On Wed, 2010-05-12 at 12:53 +0100, Sebastian Andrzej Siewior wrote:
> * Catalin Marinas | 2010-05-12 12:10:39 [+0100]:
> 
> >> > --- a/drivers/ata/libata-sff.c
> >> > +++ b/drivers/ata/libata-sff.c
> >> > @@ -894,7 +894,7 @@ static void ata_pio_sector(struct ata_queued_cmd *qc)
> >> >                                         do_write);
> >> >          }
> >> >
> >> > -       if (!do_write)
> >> > +       if (!do_write&&  !PageSlab(page))
> >> >                  flush_dcache_page(page);
> >>
> >> I would think that check belongs inside flush_dcache_page itself, rather
> >> than forcing every driver to include it..
> >
> >Sebastian (cc'ed) reported this as well for MIPS.
> Thx. The patch above looks what I've sent a while ago. Jeff was going to
> merge it afaik.
> 
> >I think it makes sense for this check to be done in the
> >flush_dcache_page() function.
> 
> Why should flush_dcache_page() not flush pages you tell it?
> From Documentation/cachetlb.txt:
> |   NOTE: This routine need only be called for page cache pages
> |          which can potentially ever be mapped into the address
> |          space of a user process.  So for example, VFS layer code
> |          handling vfs symlinks in the page cache need not call
> |          this interface at all.
> 
> A page from slab or stack is not going to see the sky of user land and
> therefore it should not be fed into flush_dcache_page().

You are right :), so fixing the driver is the best approach.

-- 
Catalin

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ