linux-stable/arch
Frank Arnold 42be450565 x86, AMD, cacheinfo: Fix L3 cache index disable checks
We provide two slots to disable cache indices, and have a check to
prevent both slots to be used for the same index.

If the user disables the same index on different subcaches, both slots
will hold the same index, e.g.

  $ echo 2047 > /sys/devices/system/cpu/cpu0/cache/index3/cache_disable_0
  $ cat /sys/devices/system/cpu/cpu0/cache/index3/cache_disable_0
  2047
  $ echo 1050623 > /sys/devices/system/cpu/cpu0/cache/index3/cache_disable_1
  $ cat /sys/devices/system/cpu/cpu0/cache/index3/cache_disable_1
  2047

due to the fact that the check was looking only at index bits [11:0]
and was ignoring writes to bits outside that range. The more correct
fix is to simply check whether the index is within the bounds of
[0..l3->indices].

While at it, cleanup comments and drop now-unused local macros.

Signed-off-by: Frank Arnold <frank.arnold@amd.com>
Link: http://lkml.kernel.org/r/1305553188-21061-3-git-send-email-bp@amd64.org
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2011-05-16 11:24:27 -07:00
..
alpha genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
arm Merge branch 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2011-03-30 09:35:52 -07:00
avr32 avr32: Fix missing irq namespace conversion 2011-03-30 15:38:03 +02:00
blackfin Merge branch 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2011-03-30 09:35:52 -07:00
cris genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
frv genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
h8300 genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
ia64 [IA64] fix build warning: argument 1 of 'irqd_irq_disabled' 2011-04-01 10:56:03 -07:00
m32r genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
m68k genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
microblaze Merge branch 'next' of git://git.monstr.eu/linux-2.6-microblaze 2011-04-04 17:54:46 -07:00
mips mips: vr41xx: Use irdq_irq_disabled() 2011-03-29 14:48:07 +02:00
mn10300 genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
parisc genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
powerpc powerpc/pseries: Fix build without CONFIG_HOTPLUG_CPU 2011-04-05 16:22:11 +10:00
s390 Merge branch 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6 2011-03-25 17:47:04 -07:00
score genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
sh genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
sparc Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6 2011-04-01 08:54:14 -07:00
tile genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
um genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
unicore32 Merge branch 'unicore32' of git://git.kernel.org/pub/scm/linux/kernel/git/epip/linux-2.6-unicore32 2011-04-04 08:33:21 -07:00
x86 x86, AMD, cacheinfo: Fix L3 cache index disable checks 2011-05-16 11:24:27 -07:00
xtensa genirq: Remove the now obsolete config options and select statements 2011-03-30 14:13:23 +02:00
.gitignore
Kconfig oprofile, s390: Cleanups 2011-03-16 14:30:40 +01:00