Re: [PATCH 01/01][retry 3] x86: L3 cache index disable for 2.6.26

From: Pavel Machek
Date: Thu Aug 14 2008 - 11:45:46 EST


Hi!

> > > + val |= 0xc0000000;
> > > + pci_write_config_dword(dev, 0x1BC + index * 4, val
> > & ~0x40000000);
> > > + wbinvd();
> > > + pci_write_config_dword(dev, 0x1BC + index * 4, val);
> >
> > Should it do if capable() test before doing such stuff?
>
> I don't think so. If it got this far, it is an AMD processor
> from family 0x10 or later, so it has wbinvd().

No, I meant we should check for permissions. Filesystem permissions
are traditionaly not enough for stuff like this. if
(capable(CAP_ADMIN)) or something?
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/