diff options
| author | Tony Lindgren <tony@atomide.com> | 2012-09-16 15:35:06 -0700 | 
|---|---|---|
| committer | Tony Lindgren <tony@atomide.com> | 2012-09-16 15:35:06 -0700 | 
| commit | 6bfc82ff589a00e5fbc12b958c649d703d273c86 (patch) | |
| tree | 9326c7213d5ccee556bff1831e8f88681a27e57c /arch/x86/kernel/microcode_amd.c | |
| parent | 26638c667e645de368cd68cade716ed0faef6269 (diff) | |
| parent | 68cb700c59fae6cd539c9dc1e9f2584f671935a0 (diff) | |
| download | olio-linux-3.10-6bfc82ff589a00e5fbc12b958c649d703d273c86.tar.xz olio-linux-3.10-6bfc82ff589a00e5fbc12b958c649d703d273c86.zip  | |
Merge tag 'omap-cleanup-sparseirq-for-v3.7' into devel-dt
This branch contains changes needed to make omap2+
work properly with sparse IRQ. It also removes
dependencies to mach/hardware.h. These help moving
things towards ARM single zImage support.
This branch is based on a commit in tty-next
branch with omap-devel-gpmc-fixed-for-v3.7 and
cleanup-omap-tags-for-v3.7 merged in to keep things
compiling and sort out some merge conflicts.
Conflicts:
	arch/arm/mach-omap2/omap4-common.c
	drivers/gpio/gpio-twl4030.c
Diffstat (limited to 'arch/x86/kernel/microcode_amd.c')
| -rw-r--r-- | arch/x86/kernel/microcode_amd.c | 7 | 
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/x86/kernel/microcode_amd.c b/arch/x86/kernel/microcode_amd.c index 8a2ce8fd41c..82746f942cd 100644 --- a/arch/x86/kernel/microcode_amd.c +++ b/arch/x86/kernel/microcode_amd.c @@ -143,11 +143,12 @@ static int get_matching_microcode(int cpu, const u8 *ucode_ptr,  				  unsigned int *current_size)  {  	struct microcode_header_amd *mc_hdr; -	unsigned int actual_size; +	unsigned int actual_size, patch_size;  	u16 equiv_cpu_id;  	/* size of the current patch we're staring at */ -	*current_size = *(u32 *)(ucode_ptr + 4) + SECTION_HDR_SIZE; +	patch_size = *(u32 *)(ucode_ptr + 4); +	*current_size = patch_size + SECTION_HDR_SIZE;  	equiv_cpu_id = find_equiv_id();  	if (!equiv_cpu_id) @@ -174,7 +175,7 @@ static int get_matching_microcode(int cpu, const u8 *ucode_ptr,  	/*  	 * now that the header looks sane, verify its size  	 */ -	actual_size = verify_ucode_size(cpu, *current_size, leftover_size); +	actual_size = verify_ucode_size(cpu, patch_size, leftover_size);  	if (!actual_size)  		return 0;  |