Linux 3.0.4 in patch form
Subsystems (110)
Hi all,
As I'm getting more and more requests every day for the latest stable kernel patch, I figured it's best if I just email it out to the list, so that everyone can have a copy of it without having to dig for the past 4 patches to have something that works.
So here's the 3.0.4 patch, which can be applied on top of the 3.0 release from Linus. You can get a copy of the 3.0 release from various places around the web, I'll not be able to mail that to the whole list.
I'm also signing this message, with my "traditional" GPG key, which is in the web of trust, so as to try to provide a bit of validity to this message.
If anyone has any questions about this, please let me know.
thanks,
greg k-h
Documentation/virtual/lguest/lguest.c +3 -0
@@ -2008,6 +2008,9 @@ int main(int argc, char *argv[])/* We use a simple helper to copy the arguments separated by spaces. */ concat ((char *)(boot +1 ), argv+optind+2 ); +/* Set kernel alignment to 16M (CONFIG_PHYSICAL_ALIGN) */ + boot->hdr.kernel_alignment =0x1000000 ; +/* Boot protocol version: 2.07 supports the fields for lguest. */ boot->hdr.version =0x207 ;
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 3 PATCHLEVEL = 0 -SUBLEVEL = 0 +SUBLEVEL = 4 EXTRAVERSION = NAME = Sneaky Weasel
arch/alpha/kernel/time.c +1 -1
@@ -91,7 +91,7 @@ DEFINE_PER_CPU(u8, irq_work_pending);#define test_irq_work_pending () __get_cpu_var(irq_work_pending)#define clear_irq_work_pending () __get_cpu_var(irq_work_pending) = 0 -void set_irq_work_pending (void ) +void arch_irq_work_raise (void ) {set_irq_work_pending_flag (); }
arch/arm/mach-pxa/cm-x300.c +4 -4
@@ -161,10 +161,10 @@ static mfp_cfg_t cm_x3xx_mfp_cfg[] __initdata = {GPIO99_GPIO ,/* Ethernet IRQ */ /* RTC GPIOs */ -GPIO95_GPIO ,/* RTC CS */ -GPIO96_GPIO ,/* RTC WR */ -GPIO97_GPIO ,/* RTC RD */ -GPIO98_GPIO ,/* RTC IO */ +GPIO95_GPIO |MFP_LPM_DRIVE_HIGH ,/* RTC CS */ +GPIO96_GPIO |MFP_LPM_DRIVE_HIGH ,/* RTC WR */ +GPIO97_GPIO |MFP_LPM_DRIVE_HIGH ,/* RTC RD */ +GPIO98_GPIO ,/* RTC IO */ /* Standard I2C */ GPIO21_I2C_SCL,
arch/cris/arch-v10/drivers/sync_serial.c +3 -3
@@ -158,7 +158,7 @@ static int sync_serial_open(struct inode *inode, struct file *file);static int sync_serial_release (struct inode *inode,struct file *file);static unsigned int sync_serial_poll (struct file *filp,poll_table *wait); -static int sync_serial_ioctl (struct file *file, +static long sync_serial_ioctl (struct file *file,unsigned int cmd,unsigned long arg);static ssize_t sync_serial_write (struct file *file,const char *buf,size_t count,loff_t *ppos);
@@ -625,11 +625,11 @@ static int sync_serial_open(struct inode *inode, struct file *file) *R_IRQ_MASK1_SET =1 << port->data_avail_bit;DEBUG (printk (KERN_DEBUG "sser%d rec started\n" , dev)); } - ret =0 ; + err =0 ; out:mutex_unlock (&sync_serial_mutex); -return ret; +return err; }static int sync_serial_release (struct inode *inode,struct file *file)
arch/cris/arch-v10/kernel/irq.c +3 -0
@@ -20,6 +20,9 @@#define crisv10_mask_irq (irq_nr) (*R_VECT_MASK_CLR = 1 << (irq_nr));#define crisv10_unmask_irq (irq_nr) (*R_VECT_MASK_SET = 1 << (irq_nr)); +extern void kgdb_init (void ); +extern void breakpoint (void ); +/* don't use set_int_vector, it bypasses the linux interrupt handlers. it is * global just so that the kernel gdb can use it. */
arch/cris/include/asm/thread_info.h +3 -3
@@ -11,8 +11,6 @@#ifdef __KERNEL__ -#define __HAVE_ARCH_THREAD_INFO_ALLOCATOR -#ifndef __ASSEMBLY__#include <asm/types.h> #include <asm/processor.h>
@@ -67,8 +65,10 @@ struct thread_info {#define init_thread_info (init_thread_union.thread_info) +#define __HAVE_ARCH_THREAD_INFO_ALLOCATOR/* thread information allocation */ -#define alloc_thread_info (tsk, node) ((struct thread_info *) __get_free_pages(GFP_KERNEL,1)) +#define alloc_thread_info_node (tsk, node) \ + ((struct thread_info *) __get_free_pages(GFP_KERNEL, 1))#define free_thread_info (ti) free_pages((unsigned long) (ti), 1)#endif /* !__ASSEMBLY__ */
arch/parisc/include/asm/atomic.h +2 -2
@@ -259,10 +259,10 @@ static __inline__ int atomic_add_unless(atomic_t *v, int a, int u)#define ATOMIC64_INIT (i) ((atomic64_t) { (i) }) -static __inline__int +static __inline__s64 __atomic64_add_return (s64 i,atomic64_t *v) { -int ret; +s64 ret;unsigned long flags;_atomic_spin_lock_irqsave (v, flags);
arch/parisc/include/asm/futex.h +60 -6
111 lines not on this page · raw message
arch/parisc/include/asm/unistd.h +2 -1
@@ -821,8 +821,9 @@#define __NR_open_by_handle_at (__NR_Linux + 326)#define __NR_syncfs (__NR_Linux + 327)#define __NR_setns (__NR_Linux + 328) +#define __NR_sendmmsg (__NR_Linux + 329) -#define __NR_Linux_syscalls (__NR_setns + 1) +#define __NR_Linux_syscalls (__NR_sendmmsg + 1)#define __IGNORE_select/* newselect */
arch/parisc/kernel/syscall_table.S +1 -0
@@ -427,6 +427,7 @@ ENTRY_COMP(open_by_handle_at) ENTRY_SAME(syncfs) ENTRY_SAME(setns) + ENTRY_COMP(sendmmsg) /* Nothing yet */
arch/powerpc/kernel/crash.c +1 -5
@@ -242,12 +242,8 @@ static void crash_kexec_wait_realmode(int cpu)while (paca[i].kexec_state <KEXEC_STATE_REAL_MODE ) {barrier (); -if (!cpu_possible (i)) { +if (!cpu_possible (i) || !cpu_online (i) || (msecs <=0 ))break ; - } -if (!cpu_online (i)) { -break ; - } msecs--;mdelay (1 ); }
arch/powerpc/kernel/prom_init.c +3 -3
@@ -1020,7 +1020,7 @@ static unsigned long __init alloc_up(unsigned long size, unsigned long align) }if (addr ==0 )return 0 ; -RELOC (alloc_bottom) = addr; +RELOC (alloc_bottom) = addr + size;prom_debug (" -> %x\n" , addr);prom_debug (" alloc_bottom : %x\n" ,RELOC (alloc_bottom));
@@ -1834,7 +1834,7 @@ static void __init *make_room(unsigned long *mem_start, unsigned long *mem_end, chunk =alloc_up (room,0 );if (chunk ==0 )prom_panic ("No memory for flatten_device_tree (claim failed)" ); - *mem_end =RELOC (alloc_top); + *mem_end = chunk + room; } ret = (void *)*mem_start;
@@ -2053,7 +2053,7 @@ static void __init flatten_device_tree(void) mem_start = (unsigned long )alloc_up (room,PAGE_SIZE );if (mem_start ==0 )prom_panic ("Can't allocate initial device-tree chunk\n" ); - mem_end =RELOC (alloc_top); + mem_end = mem_start + room;/* Get root of tree */ root =call_prom ("peer" ,1 ,1 , (phandle )0 );
arch/powerpc/kernel/time.c +1 -1
@@ -544,7 +544,7 @@ DEFINE_PER_CPU(u8, irq_work_pending);#endif /* 32 vs 64 bit */ -void set_irq_work_pending (void ) +void arch_irq_work_raise (void ) {preempt_disable ();set_irq_work_pending_flag ();
arch/powerpc/platforms/pseries/dtl.c +1 -1
@@ -181,7 +181,7 @@ static void dtl_stop(struct dtl *dtl)lppaca_of (dtl->cpu).dtl_enable_mask =0x0 ; -unregister_dtl (hwcpu,__pa (dtl->buf)); +unregister_dtl (hwcpu); }static u64 dtl_current_index (struct dtl *dtl)
arch/powerpc/platforms/pseries/hvconsole.c +1 -1
@@ -73,7 +73,7 @@ int hvc_put_chars(uint32_t vtermno, const char *buf, int count)if (ret ==H_SUCCESS )return count;if (ret ==H_BUSY ) -return 0 ; +return -EAGAIN ;return -EIO ; }
arch/powerpc/platforms/pseries/kexec.c +11 -0
@@ -26,6 +26,17 @@ static void pseries_kexec_cpu_down(int crash_shutdown, int secondary)/* Don't risk a hypervisor call if we're crashing */ if (firmware_has_feature (FW_FEATURE_SPLPAR ) && !crash_shutdown) {unsigned long addr; +int ret; + +if (get_lppaca ()->dtl_enable_mask) { + ret =unregister_dtl (hard_smp_processor_id ()); +if (ret) { +pr_err ("WARNING: DTL deregistration for cpu " +"%d (hw %d) failed with %d\n" , +smp_processor_id (), +hard_smp_processor_id (), ret); + } + } addr =__pa (get_slb_shadow ());if (unregister_slb_shadow (hard_smp_processor_id (), addr))
arch/powerpc/platforms/pseries/lpar.c +1 -1
@@ -395,7 +395,7 @@ static void pSeries_lpar_hptab_clear(void)unsigned long ptel; } ptes[4 ];long lpar_rc; -int i, j; +unsigned long i, j;/* Read in batches of 4, * invalidate only valid entries not in the VRMA
arch/powerpc/platforms/pseries/plpar_wrappers.h +2 -2
@@ -73,9 +73,9 @@ static inline long register_slb_shadow(unsigned long cpu, unsigned long vpa)return vpa_call (0x3 , cpu, vpa); } -static inline long unregister_dtl (unsigned long cpu,unsigned long vpa) +static inline long unregister_dtl (unsigned long cpu) { -return vpa_call (0x6 , cpu, vpa); +return vpa_call (0x6 , cpu,0 ); }static inline long register_dtl (unsigned long cpu,unsigned long vpa)
arch/sparc/include/asm/bitops_64.h +8 -41
69 lines not on this page · raw message
arch/sparc/include/asm/elf_64.h +29 -34
75 lines not on this page · raw message
arch/sparc/include/asm/hypervisor.h +14 -0
@@ -2927,6 +2927,13 @@ extern unsigned long sun4v_ncs_request(unsigned long request,#define HV_FAST_FIRE_GET_PERFREG 0x120#define HV_FAST_FIRE_SET_PERFREG 0x121 +#define HV_FAST_REBOOT_DATA_SET 0x172 + +#ifndef __ASSEMBLY__ +extern unsigned long sun4v_reboot_data_set (unsigned long ra, +unsigned long len); +#endif +/* Function numbers for HV_CORE_TRAP. */ #define HV_CORE_SET_VER 0x00#define HV_CORE_PUTCHAR 0x01
@@ -2940,16 +2947,23 @@ extern unsigned long sun4v_ncs_request(unsigned long request,#define HV_GRP_CORE 0x0001#define HV_GRP_INTR 0x0002#define HV_GRP_SOFT_STATE 0x0003 +#define HV_GRP_TM 0x0080#define HV_GRP_PCI 0x0100#define HV_GRP_LDOM 0x0101#define HV_GRP_SVC_CHAN 0x0102#define HV_GRP_NCS 0x0103#define HV_GRP_RNG 0x0104 +#define HV_GRP_PBOOT 0x0105 +#define HV_GRP_TPM 0x0107 +#define HV_GRP_SDIO 0x0108 +#define HV_GRP_SDIO_ERR 0x0109 +#define HV_GRP_REBOOT_DATA 0x0110#define HV_GRP_NIAG_PERF 0x0200#define HV_GRP_FIRE_PERF 0x0201#define HV_GRP_N2_CPU 0x0202#define HV_GRP_NIU 0x0204#define HV_GRP_VF_CPU 0x0205 +#define HV_GRP_KT_CPU 0x0209#define HV_GRP_DIAG 0x0300#ifndef __ASSEMBLY__
arch/sparc/include/asm/spitfire.h +1 -0
@@ -42,6 +42,7 @@#define SUN4V_CHIP_INVALID 0x00#define SUN4V_CHIP_NIAGARA1 0x01#define SUN4V_CHIP_NIAGARA2 0x02 +#define SUN4V_CHIP_NIAGARA3 0x03#define SUN4V_CHIP_UNKNOWN 0xff#ifndef __ASSEMBLY__
arch/sparc/include/asm/tsb.h +24 -27
84 lines not on this page · raw message
arch/sparc/include/asm/xor_64.h +2 -1
@@ -65,6 +65,7 @@ static struct xor_block_template xor_block_niagara = {#define XOR_SELECT_TEMPLATE (FASTEST ) \ ((tlb_type == hypervisor && \ (sun4v_chip_type == SUN4V_CHIP_NIAGARA1 || \ - sun4v_chip_type == SUN4V_CHIP_NIAGARA2)) ? \ + sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || \ + sun4v_chip_type == SUN4V_CHIP_NIAGARA3)) ? \ &xor_block_niagara : \ &xor_block_VIS)
arch/sparc/kernel/cpu.c +8 -0
@@ -396,6 +396,7 @@ static int show_cpuinfo(struct seq_file *m, void *__unused) , cpu_data(0).clock_tick#endif ); +cpucap_info (m);#ifdef CONFIG_SMP smp_bogo (m);#endif
@@ -474,11 +475,18 @@ static void __init sun4v_cpu_probe(void) sparc_pmu_type ="niagara2" ;break ; +case SUN4V_CHIP_NIAGARA3 : + sparc_cpu_type ="UltraSparc T3 (Niagara3)" ; + sparc_fpu_type ="UltraSparc T3 integrated FPU" ; + sparc_pmu_type ="niagara3" ; +break ; +default :printk (KERN_WARNING "CPU: Unknown sun4v cpu type [%s]\n" , prom_cpu_compatible); sparc_cpu_type ="Unknown SUN4V CPU" ; sparc_fpu_type ="Unknown SUN4V FPU" ; + sparc_pmu_type ="Unknown SUN4V PMU" ;break ; } }
arch/sparc/kernel/cpumap.c +1 -0
@@ -324,6 +324,7 @@ static int iterate_cpu(struct cpuinfo_tree *t, unsigned int root_index)switch (sun4v_chip_type) {case SUN4V_CHIP_NIAGARA1 :case SUN4V_CHIP_NIAGARA2 : +case SUN4V_CHIP_NIAGARA3 : rover_inc_table = niagara_iterate_method;break ;default :
arch/sparc/kernel/ds.c +29 -2
@@ -15,12 +15,15 @@#include <linux/reboot.h> #include <linux/cpu.h> +#include <asm/hypervisor.h> #include <asm/ldc.h> #include <asm/vio.h> #include <asm/mdesc.h> #include <asm/head.h> #include <asm/irq.h> +#include "kernel.h" +#define DRV_MODULE_NAME "ds"#define PFX DRV_MODULE_NAME ": "#define DRV_MODULE_VERSION "1.0"
@@ -828,18 +831,32 @@ void ldom_set_var(const char *var, const char *value) } } +static char full_boot_str[256] __attribute__((aligned(32))); +static int reboot_data_supported; +void ldom_reboot (const char *boot_command) {/* Don't bother with any of this if the boot_command * is empty. */ if (boot_command &&strlen (boot_command)) { -char full_boot_str[256 ]; +unsigned long len;strcpy (full_boot_str,"boot " );strcpy (full_boot_str +strlen ("boot " ), boot_command); + len =strlen (full_boot_str); -ldom_set_var ("reboot-command" , full_boot_str); +if (reboot_data_supported) { +unsigned long ra =kimage_addr_to_ra (full_boot_str); +unsigned long hv_ret; + + hv_ret =sun4v_reboot_data_set (ra, len); +if (hv_ret !=HV_EOK ) +pr_err ("SUN4V: Unable to set reboot data " +"hv_ret=%lu\n" , hv_ret); + }else { +ldom_set_var ("reboot-command" , full_boot_str); + } }sun4v_mach_sir (); }
@@ -1237,6 +1254,16 @@ static struct vio_driver ds_driver = {static int __init ds_init (void ) { +unsigned long hv_ret, major, minor; + +if (tlb_type == hypervisor) { + hv_ret =sun4v_get_version (HV_GRP_REBOOT_DATA , &major, &minor); +if (hv_ret ==HV_EOK ) { +pr_info ("SUN4V: Reboot data supported (maj=%lu,min=%lu).\n" , + major, minor); + reboot_data_supported =1 ; + } + }kthread_run (ds_thread,NULL ,"kldomd" );return vio_register_driver (&ds_driver);
arch/sparc/kernel/entry.h +14 -0
@@ -42,6 +42,20 @@ extern void fpsave(unsigned long *fpregs, unsigned long *fsr,extern void fpload (unsigned long *fpregs,unsigned long *fsr);#else /* CONFIG_SPARC32 */ +struct popc_3insn_patch_entry { +unsigned int addr; +unsigned int insns[3 ]; +}; +extern struct popc_3insn_patch_entry __popc_3insn_patch, + __popc_3insn_patch_end; + +struct popc_6insn_patch_entry { +unsigned int addr; +unsigned int insns[6 ]; +}; +extern struct popc_6insn_patch_entry __popc_6insn_patch, + __popc_6insn_patch_end; +extern void __init per_cpu_patch (void );extern void __init sun4v_patch (void );extern void __init boot_cpu_id_too_large (int cpu);
arch/sparc/kernel/head_64.S +32 -1
@@ -132,6 +132,8 @@ prom_sun4v_name: .asciz "sun4v" prom_niagara_prefix: .asciz "SUNW,UltraSPARC-T" +prom_sparc_prefix: + .asciz "SPARC-T" .align 4 prom_root_compatible: .skip 64
@@ -382,6 +384,22 @@ sun4v_chip_type: 90: ldub [%g7], %g2 ldub [%g1], %g4 cmp %g2, %g4 + bne,pn %icc, 89f + add %g7, 1, %g7 + subcc %g3, 1, %g3 + bne,pt %xcc, 90b + add %g1, 1, %g1 + ba,pt %xcc, 91f + nop + +89: sethi %hi(prom_cpu_compatible), %g1 + or %g1, %lo(prom_cpu_compatible), %g1 + sethi %hi(prom_sparc_prefix), %g7 + or %g7, %lo(prom_sparc_prefix), %g7 + mov 7, %g3 +90: ldub [%g7], %g2 + ldub [%g1], %g4 + cmp %g2, %g4 bne,pn %icc, 4f add %g7, 1, %g7 subcc %g3, 1, %g3
@@ -390,6 +408,15 @@ sun4v_chip_type: sethi %hi(prom_cpu_compatible), %g1 or %g1, %lo(prom_cpu_compatible), %g1 + ldub [%g1 + 7], %g2 + cmp %g2, '3' + be,pt %xcc, 5f + mov SUN4V_CHIP_NIAGARA3, %g4 + ba,pt %xcc, 4f + nop + +91: sethi %hi(prom_cpu_compatible), %g1 + or %g1, %lo(prom_cpu_compatible), %g1 ldub [%g1 + 17], %g2 cmp %g2, '1' be,pt %xcc, 5f
@@ -397,6 +424,7 @@ sun4v_chip_type: cmp %g2, '2' be,pt %xcc, 5f mov SUN4V_CHIP_NIAGARA2, %g4 + 4: mov SUN4V_CHIP_UNKNOWN, %g4 5: sethi %hi(sun4v_chip_type), %g2
@@ -514,6 +542,9 @@ niagara_tlb_fixup: cmp %g1, SUN4V_CHIP_NIAGARA2 be,pt %xcc, niagara2_patch nop + cmp %g1, SUN4V_CHIP_NIAGARA3 + be,pt %xcc, niagara2_patch + nop call generic_patch_copyops nop
@@ -528,7 +559,7 @@ niagara2_patch: nop call niagara_patch_bzero nop - call niagara2_patch_pageops + call niagara_patch_pageops nop ba,a,pt %xcc, 80f
arch/sparc/kernel/hvapi.c +7 -0
@@ -28,16 +28,23 @@ static struct api_info api_table[] = { { .group = HV_GRP_CORE, .flags = FLAG_PRE_API }, { .group = HV_GRP_INTR, }, { .group = HV_GRP_SOFT_STATE, }, + { .group = HV_GRP_TM, }, { .group = HV_GRP_PCI, .flags = FLAG_PRE_API }, { .group = HV_GRP_LDOM, }, { .group = HV_GRP_SVC_CHAN, .flags = FLAG_PRE_API }, { .group = HV_GRP_NCS, .flags = FLAG_PRE_API }, { .group = HV_GRP_RNG, }, + { .group = HV_GRP_PBOOT, }, + { .group = HV_GRP_TPM, }, + { .group = HV_GRP_SDIO, }, + { .group = HV_GRP_SDIO_ERR, }, + { .group = HV_GRP_REBOOT_DATA, }, { .group = HV_GRP_NIAG_PERF, .flags = FLAG_PRE_API }, { .group = HV_GRP_FIRE_PERF, }, { .group = HV_GRP_N2_CPU, }, { .group = HV_GRP_NIU, }, { .group = HV_GRP_VF_CPU, }, + { .group = HV_GRP_KT_CPU, }, { .group = HV_GRP_DIAG, .flags = FLAG_PRE_API }, };
arch/sparc/kernel/hvcalls.S +7 -0
@@ -798,3 +798,10 @@ ENTRY(sun4v_niagara2_setperf) retl nop ENDPROC(sun4v_niagara2_setperf) + +ENTRY(sun4v_reboot_data_set) + mov HV_FAST_REBOOT_DATA_SET, %o5 + ta HV_FAST_TRAP + retl + nop +ENDPROC(sun4v_reboot_data_set)
arch/sparc/kernel/kernel.h +15 -0
@@ -4,12 +4,27 @@#include <linux/interrupt.h> #include <asm/traps.h> +#include <asm/head.h> +#include <asm/io.h> /* cpu.c */ extern const char *sparc_pmu_type;extern unsigned int fsr_storage;extern int ncpus_probed; +#ifdef CONFIG_SPARC64 +/* setup_64.c */ +struct seq_file ; +extern void cpucap_info (struct seq_file *); + +static inline unsigned long kimage_addr_to_ra (const char *p) +{ +unsigned long val = (unsigned long ) p; + +return kern_base + (val -KERNBASE ); +} +#endif +#ifdef CONFIG_SPARC32 /* cpu.c */ extern void cpu_probe (void );
arch/sparc/kernel/ktlb.S +12 -12
@@ -47,16 +47,16 @@ kvmap_itlb_tsb_miss: kvmap_itlb_vmalloc_addr: KERN_PGTABLE_WALK(%g4, %g5, %g2, kvmap_itlb_longpath) - KTSB_LOCK_TAG(%g1, %g2, %g7) + TSB_LOCK_TAG(%g1, %g2, %g7) /* Load and check PTE. */ ldxa [%g5] ASI_PHYS_USE_EC, %g5 mov 1, %g7 sllx %g7, TSB_TAG_INVALID_BIT, %g7 brgez,a,pn %g5, kvmap_itlb_longpath - KTSB_STORE(%g1, %g7) + TSB_STORE(%g1, %g7) - KTSB_WRITE(%g1, %g5, %g6) + TSB_WRITE(%g1, %g5, %g6) /* fallthrough to TLB load */
@@ -102,9 +102,9 @@ kvmap_itlb_longpath: kvmap_itlb_obp: OBP_TRANS_LOOKUP(%g4, %g5, %g2, %g3, kvmap_itlb_longpath) - KTSB_LOCK_TAG(%g1, %g2, %g7) + TSB_LOCK_TAG(%g1, %g2, %g7) - KTSB_WRITE(%g1, %g5, %g6) + TSB_WRITE(%g1, %g5, %g6) ba,pt %xcc, kvmap_itlb_load nop
@@ -112,17 +112,17 @@ kvmap_itlb_obp: kvmap_dtlb_obp: OBP_TRANS_LOOKUP(%g4, %g5, %g2, %g3, kvmap_dtlb_longpath) - KTSB_LOCK_TAG(%g1, %g2, %g7) + TSB_LOCK_TAG(%g1, %g2, %g7) - KTSB_WRITE(%g1, %g5, %g6) + TSB_WRITE(%g1, %g5, %g6) ba,pt %xcc, kvmap_dtlb_load nop .align 32 kvmap_dtlb_tsb4m_load: - KTSB_LOCK_TAG(%g1, %g2, %g7) - KTSB_WRITE(%g1, %g5, %g6) + TSB_LOCK_TAG(%g1, %g2, %g7) + TSB_WRITE(%g1, %g5, %g6) ba,pt %xcc, kvmap_dtlb_load nop
@@ -222,16 +222,16 @@ kvmap_linear_patch: kvmap_dtlb_vmalloc_addr: KERN_PGTABLE_WALK(%g4, %g5, %g2, kvmap_dtlb_longpath) - KTSB_LOCK_TAG(%g1, %g2, %g7) + TSB_LOCK_TAG(%g1, %g2, %g7) /* Load and check PTE. */ ldxa [%g5] ASI_PHYS_USE_EC, %g5 mov 1, %g7 sllx %g7, TSB_TAG_INVALID_BIT, %g7 brgez,a,pn %g5, kvmap_dtlb_longpath - KTSB_STORE(%g1, %g7) + TSB_STORE(%g1, %g7) - KTSB_WRITE(%g1, %g5, %g6) + TSB_WRITE(%g1, %g5, %g6) /* fallthrough to TLB load */
arch/sparc/kernel/mdesc.c +23 -7
@@ -508,6 +508,8 @@ const char *mdesc_node_name(struct mdesc_handle *hp, u64 node) }EXPORT_SYMBOL (mdesc_node_name); +static u64 max_cpus =64 ; +static void __init report_platform_properties (void ) {struct mdesc_handle *hp =mdesc_grab ();
@@ -543,8 +545,10 @@ static void __init report_platform_properties(void)if (v)printk ("PLATFORM: watchdog-max-timeout [%llu ms]\n" , *v); v =mdesc_get_property (hp, pn,"max-cpus" ,NULL ); -if (v) -printk ("PLATFORM: max-cpus [%llu]\n" , *v); +if (v) { + max_cpus = *v; +printk ("PLATFORM: max-cpus [%llu]\n" , max_cpus); + }#ifdef CONFIG_SMP {
@@ -715,7 +719,7 @@ static void __cpuinit set_proc_ids(struct mdesc_handle *hp) }static void __cpuinit get_one_mondo_bits (const u64 *p,unsigned int *mask, -unsigned char def) +unsigned long def,unsigned long max) {u64 val;
@@ -726,6 +730,9 @@ static void __cpuinit get_one_mondo_bits(const u64 *p, unsigned int *mask,if (!val || val >=64 ) goto use_default; +if (val > max) + val = max; + *mask = ((1U << val) *64U ) -1U ;return ;
@@ -736,19 +743,28 @@ use_default:static void __cpuinit get_mondo_data (struct mdesc_handle *hp,u64 mp,struct trap_per_cpu *tb) { +static int printed;const u64 *val; val =mdesc_get_property (hp, mp,"q-cpu-mondo-#bits" ,NULL ); -get_one_mondo_bits (val, &tb->cpu_mondo_qmask,7 ); +get_one_mondo_bits (val, &tb->cpu_mondo_qmask,7 ,ilog2 (max_cpus *2 )); val =mdesc_get_property (hp, mp,"q-dev-mondo-#bits" ,NULL ); -get_one_mondo_bits (val, &tb->dev_mondo_qmask,7 ); +get_one_mondo_bits (val, &tb->dev_mondo_qmask,7 ,8 ); val =mdesc_get_property (hp, mp,"q-resumable-#bits" ,NULL ); -get_one_mondo_bits (val, &tb->resum_qmask,6 ); +get_one_mondo_bits (val, &tb->resum_qmask,6 ,7 ); val =mdesc_get_property (hp, mp,"q-nonresumable-#bits" ,NULL ); -get_one_mondo_bits (val, &tb->nonresum_qmask,2 ); +get_one_mondo_bits (val, &tb->nonresum_qmask,2 ,2 ); +if (!printed++) { +pr_info ("SUN4V: Mondo queue sizes " +"[cpu(%u) dev(%u) r(%u) nr(%u)]\n" , + tb->cpu_mondo_qmask +1 , + tb->dev_mondo_qmask +1 , + tb->resum_qmask +1 , + tb->nonresum_qmask +1 ); + } }static void *__cpuinit mdesc_iterate_over_cpus (void *(*func)(struct mdesc_handle *,u64 ,int ,void *),void *arg,cpumask_t *mask)
arch/sparc/kernel/pcr.c +9 -2
@@ -80,8 +80,11 @@ static void n2_pcr_write(u64 val) {unsigned long ret; - ret =sun4v_niagara2_setperf (HV_N2_PERF_SPARC_CTL , val); -if (ret !=HV_EOK ) +if (val &PCR_N2_HTRACE ) { + ret =sun4v_niagara2_setperf (HV_N2_PERF_SPARC_CTL , val); +if (ret !=HV_EOK ) +write_pcr (val); + }else write_pcr (val); }
@@ -106,6 +109,10 @@ static int __init register_perf_hsvc(void) perf_hsvc_group =HV_GRP_N2_CPU ;break ; +case SUN4V_CHIP_NIAGARA3 : + perf_hsvc_group =HV_GRP_KT_CPU ; +break ; +default :return -ENODEV ; }
arch/sparc/kernel/perf_event.c +2 -1
@@ -1301,7 +1301,8 @@ static bool __init supported_pmu(void) sparc_pmu = &niagara1_pmu;return true; } -if (!strcmp (sparc_pmu_type,"niagara2" )) { +if (!strcmp (sparc_pmu_type,"niagara2" ) || + !strcmp (sparc_pmu_type,"niagara3" )) { sparc_pmu = &niagara2_pmu;return true; }
arch/sparc/kernel/setup_64.c +186 -0
216 lines not on this page · raw message
arch/sparc/kernel/sparc_ksyms_64.c +11 -0
@@ -8,6 +8,7 @@#include <linux/module.h> #include <linux/pci.h> #include <linux/init.h> +#include <linux/bitops.h> #include <asm/system.h> #include <asm/cpudata.h>
@@ -38,5 +39,15 @@ EXPORT_SYMBOL(sun4v_niagara_setperf);EXPORT_SYMBOL (sun4v_niagara2_getperf);EXPORT_SYMBOL (sun4v_niagara2_setperf); +/* from hweight.S */ +EXPORT_SYMBOL (__arch_hweight8); +EXPORT_SYMBOL (__arch_hweight16); +EXPORT_SYMBOL (__arch_hweight32); +EXPORT_SYMBOL (__arch_hweight64); + +/* from ffs_ffz.S */ +EXPORT_SYMBOL (ffs); +EXPORT_SYMBOL (__ffs); +/* Exporting a symbol from /init/main.c */ EXPORT_SYMBOL (saved_command_line);
arch/sparc/kernel/sstate.c +2 -7
@@ -14,14 +14,9 @@#include <asm/head.h> #include <asm/io.h> -static int hv_supports_soft_state; - -static unsigned long kimage_addr_to_ra (const char *p) -{ -unsigned long val = (unsigned long ) p; +#include "kernel.h" -return kern_base + (val -KERNBASE ); -} +static int hv_supports_soft_state;static void do_set_sstate (unsigned long state,const char *msg) {
arch/sparc/kernel/unaligned_64.c +4 -11
@@ -22,6 +22,7 @@#include <linux/bitops.h> #include <linux/perf_event.h> #include <linux/ratelimit.h> +#include <linux/bitops.h> #include <asm/fpumacro.h> enum direction {
@@ -373,16 +374,11 @@ asmlinkage void kernel_unaligned_trap(struct pt_regs *regs, unsigned int insn) } } -static char popc_helper[] = { -0 ,1 ,1 ,2 ,1 ,2 ,2 ,3 , -1 ,2 ,2 ,3 ,2 ,3 ,3 ,4 , -}; -int handle_popc (u32 insn,struct pt_regs *regs) { -u64 value; -int ret, i, rd = ((insn >>25 ) &0x1f );int from_kernel = (regs->tstate &TSTATE_PRIV ) !=0 ; +int ret, rd = ((insn >>25 ) &0x1f ); +u64 value;perf_sw_event (PERF_COUNT_SW_EMULATION_FAULTS ,1 ,0 , regs,0 );if (insn &0x2000 ) {
@@ -392,10 +388,7 @@ int handle_popc(u32 insn, struct pt_regs *regs)maybe_flush_windows (0 , insn &0x1f , rd, from_kernel); value =fetch_reg (insn &0x1f , regs); } -for (ret =0 , i =0 ; i <16 ; i++) { - ret += popc_helper[value &0xf ]; - value >>=4 ; - } + ret =hweight64 (value);if (rd <16 ) {if (rd) regs->u_regs[rd] = ret;
arch/sparc/kernel/vmlinux.lds.S +20 -1
@@ -107,7 +107,26 @@ SECTIONS *(.sun4v_2insn_patch) __sun4v_2insn_patch_end = .; } - + .swapper_tsb_phys_patch : { + __swapper_tsb_phys_patch = .; + *(.swapper_tsb_phys_patch) + __swapper_tsb_phys_patch_end = .; + } + .swapper_4m_tsb_phys_patch : { + __swapper_4m_tsb_phys_patch = .; + *(.swapper_4m_tsb_phys_patch) + __swapper_4m_tsb_phys_patch_end = .; + } + .popc_3insn_patch : { + __popc_3insn_patch = .; + *(.popc_3insn_patch) + __popc_3insn_patch_end = .; + } + .popc_6insn_patch : { + __popc_6insn_patch = .; + *(.popc_6insn_patch) + __popc_6insn_patch_end = .; + } PERCPU_SECTION(SMP_CACHE_BYTES) . = ALIGN(PAGE_SIZE);
arch/sparc/lib/Makefile +2 -2
@@ -31,13 +31,13 @@ lib-$(CONFIG_SPARC64) += NGmemcpy.o NGcopy_from_user.o NGcopy_to_user.o lib-$(CONFIG_SPARC64) += NGpatch.o NGpage.o NGbzero.o lib-$(CONFIG_SPARC64) += NG2memcpy.o NG2copy_from_user.o NG2copy_to_user.o -lib-$(CONFIG_SPARC64) += NG2patch.o NG2page.o +lib-$(CONFIG_SPARC64) += NG2patch.o lib-$(CONFIG_SPARC64) += GENmemcpy.o GENcopy_from_user.o GENcopy_to_user.o lib-$(CONFIG_SPARC64) += GENpatch.o GENpage.o GENbzero.o lib-$(CONFIG_SPARC64) += copy_in_user.o user_fixup.o memmove.o -lib-$(CONFIG_SPARC64) += mcount.o ipcsum.o xor.o +lib-$(CONFIG_SPARC64) += mcount.o ipcsum.o xor.o hweight.o ffs.o obj-y += iomap.o obj-$(CONFIG_SPARC32) += atomic32.o
arch/sparc/lib/NG2page.S deleted +0 -61
61 lines not on this page · raw message
arch/sparc/lib/NGpage.S +75 -39
130 lines not on this page · raw message
arch/sparc/lib/ffs.S new file +84 -0
84 lines not on this page · raw message
arch/sparc/lib/hweight.S new file +51 -0
51 lines not on this page · raw message
arch/sparc/mm/init_64.c +41 -1
55 lines not on this page · raw message
arch/x86/include/asm/msr-index.h +3 -0
@@ -259,6 +259,9 @@#define MSR_IA32_TEMPERATURE_TARGET 0x000001a2#define MSR_IA32_ENERGY_PERF_BIAS 0x000001b0 +#define ENERGY_PERF_BIAS_PERFORMANCE 0 +#define ENERGY_PERF_BIAS_NORMAL 6 +#define ENERGY_PERF_BIAS_POWERSWAVE 15#define MSR_IA32_PACKAGE_THERM_STATUS 0x000001b1
arch/x86/include/asm/xen/page.h +2 -2
@@ -39,7 +39,7 @@ typedef struct xpaddr { ((unsigned long)((u64)CONFIG_XEN_MAX_DOMAIN_MEMORY * 1024 * 1024 * 1024 / PAGE_SIZE))extern unsigned long *machine_to_phys_mapping; -extern unsigned int machine_to_phys_order; +extern unsigned long machine_to_phys_nr;extern unsigned long get_phys_to_machine (unsigned long pfn);extern bool set_phys_to_machine (unsigned long pfn,unsigned long mfn);
@@ -87,7 +87,7 @@ static inline unsigned long mfn_to_pfn(unsigned long mfn)if (xen_feature (XENFEAT_auto_translated_physmap))return mfn; -if (unlikely ((mfn >> machine_to_phys_order) !=0 )) { +if (unlikely (mfn >= machine_to_phys_nr)) { pfn = ~0 ; goto try_override; }
arch/x86/kernel/apic/x2apic_uv_x.c +0 -1
@@ -207,7 +207,6 @@ static int __cpuinit uv_wakeup_secondary(int phys_apicid, unsigned long start_ri ((start_rip <<UVH_IPI_INT_VECTOR_SHFT ) >>12 ) |APIC_DM_INIT ;uv_write_global_mmr64 (pnode,UVH_IPI_INT , val); -mdelay (10 ); val = (1UL <<UVH_IPI_INT_SEND_SHFT ) | (phys_apicid << UVH_IPI_INT_APIC_ID_SHFT) |
arch/x86/kernel/cpu/intel.c +18 -0
@@ -456,6 +456,24 @@ static void __cpuinit init_intel(struct cpuinfo_x86 *c)if (cpu_has (c,X86_FEATURE_VMX ))detect_vmx_virtcap (c); + +/* +* Initialize MSR_IA32_ENERGY_PERF_BIAS if BIOS did not. +* x86_energy_perf_policy(8) is available to change it at run-time +*/ +if (cpu_has (c,X86_FEATURE_EPB )) { +u64 epb; + +rdmsrl (MSR_IA32_ENERGY_PERF_BIAS , epb); +if ((epb &0xF ) ==ENERGY_PERF_BIAS_PERFORMANCE ) { +printk_once (KERN_WARNING "ENERGY_PERF_BIAS:" +" Set to 'normal', was 'performance'\n" +"ENERGY_PERF_BIAS: View and update with" +" x86_energy_perf_policy(8)\n" ); + epb = (epb & ~0xF ) |ENERGY_PERF_BIAS_NORMAL ; +wrmsrl (MSR_IA32_ENERGY_PERF_BIAS , epb); + } + } }#ifdef CONFIG_X86_32
arch/x86/kernel/cpu/mtrr/main.c +23 -0
@@ -248,6 +248,25 @@ set_mtrr(unsigned int reg, unsigned long base, unsigned long size, mtrr_type typunsigned long flags;int cpu; +#ifdef CONFIG_SMP +/* +* If this cpu is not yet active, we are in the cpu online path. There +* can be no stop_machine() in parallel, as stop machine ensures this +* by using get_online_cpus(). We can skip taking the stop_cpus_mutex, +* as we don't need it and also we can't afford to block while waiting +* for the mutex. +* +* If this cpu is active, we need to prevent stop_machine() happening +* in parallel by taking the stop cpus mutex. +* +* Also, this is called in the context of cpu online path or in the +* context where cpu hotplug is prevented. So checking the active status +* of the raw_smp_processor_id() is safe. +*/ +if (cpu_active (raw_smp_processor_id ())) +mutex_lock (&stop_cpus_mutex); +#endif +preempt_disable (); data.smp_reg = reg;
@@ -330,6 +349,10 @@ set_mtrr(unsigned int reg, unsigned long base, unsigned long size, mtrr_type typlocal_irq_restore (flags);preempt_enable (); +#ifdef CONFIG_SMP +if (cpu_active (raw_smp_processor_id ())) +mutex_unlock (&stop_cpus_mutex); +#endif }/**
arch/x86/kernel/relocate_kernel_32.S +2 -0
@@ -97,6 +97,8 @@ relocate_kernel: ret identity_mapped: + /* set return address to 0 if not preserving context */ + pushl $0 /* store the start address on the stack */ pushl %edx
arch/x86/kernel/relocate_kernel_64.S +2 -0
@@ -100,6 +100,8 @@ relocate_kernel: ret identity_mapped: + /* set return address to 0 if not preserving context */ + pushq $0 /* store the start address on the stack */ pushq %rdx
arch/x86/oprofile/backtrace.c +47 -9
86 lines not on this page · raw message
arch/x86/platform/olpc/olpc.c +2 -2
@@ -157,13 +157,13 @@ restart:if (inbuf && inlen) {/* write data to EC */ for (i =0 ; i < inlen; i++) { +pr_devel ("olpc-ec: sending cmd arg 0x%x\n" , inbuf[i]); +outb (inbuf[i],0x68 );if (wait_on_ibf (0x6c ,0 )) {printk (KERN_ERR "olpc-ec: timeout waiting for" " EC accept data!\n" ); goto err; } -pr_devel ("olpc-ec: sending cmd arg 0x%x\n" , inbuf[i]); -outb (inbuf[i],0x68 ); } }if (outbuf && outlen) {
arch/x86/vdso/vdso32/sysenter.S +1 -1
@@ -43,7 +43,7 @@ __kernel_vsyscall: .space 7,0x90 /* 14: System call restart point is here! (SYSENTER_RETURN-2) */ - jmp .Lenter_kernel + int $0x80 /* 16: System call normal return point is here! */ VDSO32_SYSENTER_RETURN: /* Symbol used by sysenter.c via vdso32-syms.h */ pop %ebp
arch/x86/xen/Makefile +1 -1
@@ -18,5 +18,5 @@ obj-y := enlighten.o setup.o multicalls.o mmu.o irq.o \ obj-$(CONFIG_SMP) += smp.o obj-$(CONFIG_PARAVIRT_SPINLOCKS)+= spinlock.o obj-$(CONFIG_XEN_DEBUG_FS) += debugfs.o - +obj-$(CONFIG_XEN_DOM0) += vga.o obj-$(CONFIG_SWIOTLB_XEN) += pci-swiotlb-xen.o
arch/x86/xen/enlighten.c +10 -2
@@ -77,8 +77,8 @@ EXPORT_SYMBOL_GPL(xen_domain_type);unsigned long *machine_to_phys_mapping = (void *)MACH2PHYS_VIRT_START ;EXPORT_SYMBOL (machine_to_phys_mapping); -unsigned int machine_to_phys_order; -EXPORT_SYMBOL (machine_to_phys_order); +unsigned long machine_to_phys_nr; +EXPORT_SYMBOL (machine_to_phys_nr);struct start_info *xen_start_info;EXPORT_SYMBOL_GPL (xen_start_info);
@@ -1248,6 +1248,14 @@ asmlinkage void __init xen_start_kernel(void)if (pci_xen) x86_init.pci.arch_init = pci_xen_init; }else { +const struct dom0_vga_console_info *info = + (void *)((char *)xen_start_info + + xen_start_info->console.dom0.info_off); + +xen_init_vga (info, xen_start_info->console.dom0.info_size); + xen_start_info->console.domU.mfn =0 ; + xen_start_info->console.domU.evtchn =0 ; +/* Make sure ACS will be enabled */ pci_request_acs (); }
arch/x86/xen/mmu.c +8 -4
@@ -1626,15 +1626,19 @@ static void __init xen_map_identity_early(pmd_t *pmd, unsigned long max_pfn)void __init xen_setup_machphys_mapping (void ) {struct xen_machphys_mapping mapping; -unsigned long machine_to_phys_nr_ents;if (HYPERVISOR_memory_op (XENMEM_machphys_mapping, &mapping) ==0 ) { machine_to_phys_mapping = (unsigned long *)mapping.v_start; - machine_to_phys_nr_ents = mapping.max_mfn +1 ; + machine_to_phys_nr = mapping.max_mfn +1 ; }else { - machine_to_phys_nr_ents =MACH2PHYS_NR_ENTRIES ; + machine_to_phys_nr =MACH2PHYS_NR_ENTRIES ; } - machine_to_phys_order =fls (machine_to_phys_nr_ents -1 ); +#ifdef CONFIG_X86_32 +if ((machine_to_phys_mapping + machine_to_phys_nr) + < machine_to_phys_mapping) + machine_to_phys_nr = (unsigned long *)NULL + - machine_to_phys_mapping; +#endif }#ifdef CONFIG_X86_64
arch/x86/xen/smp.c +2 -2
@@ -521,8 +521,6 @@ static void __init xen_hvm_smp_prepare_cpus(unsigned int max_cpus)native_smp_prepare_cpus (max_cpus);WARN_ON (xen_smp_intr_init (0 )); -if (!xen_have_vector_callback) -return ;xen_init_lock_cpu (0 );xen_init_spinlocks (); }
@@ -546,6 +544,8 @@ static void xen_hvm_cpu_die(unsigned int cpu)void __init xen_hvm_smp_init (void ) { +if (!xen_have_vector_callback) +return ; smp_ops.smp_prepare_cpus = xen_hvm_smp_prepare_cpus; smp_ops.smp_send_reschedule = xen_smp_send_reschedule; smp_ops.cpu_up = xen_hvm_cpu_up;
arch/x86/xen/vga.c new file +67 -0
67 lines not on this page · raw message
arch/x86/xen/xen-ops.h +11 -0
@@ -88,6 +88,17 @@ static inline void xen_uninit_lock_cpu(int cpu) }#endif +struct dom0_vga_console_info ; + +#ifdef CONFIG_XEN_DOM0 +void __init xen_init_vga (const struct dom0_vga_console_info *,size_t size); +#else +static inline void __init xen_init_vga (const struct dom0_vga_console_info *info, +size_t size) +{ +} +#endif +/* Declare an asm function, along with symbols needed to make it inlineable */ #define DECL_ASM (ret, name, ...) \
arch/xtensa/kernel/ptrace.c +3 -0
@@ -147,6 +147,9 @@ int ptrace_setxregs(struct task_struct *child, void __user *uregs)elf_xtregs_t *xtregs = uregs;int ret =0 ; +if (!access_ok (VERIFY_READ , uregs,sizeof (elf_xtregs_t))) +return -EFAULT ; +#if XTENSA_HAVE_COPROCESSORS /* Flush all coprocessors before we overwrite them. */ coprocessor_flush_all (ti);
block/blk-core.c +3 -0
@@ -839,6 +839,9 @@ struct request *blk_get_request(struct request_queue *q, int rw, gfp_t gfp_mask) {struct request *rq; +if (unlikely (test_bit (QUEUE_FLAG_DEAD , &q->queue_flags))) +return NULL ; +BUG_ON (rw !=READ && rw !=WRITE );spin_lock_irq (q->queue_lock);
block/blk-exec.c +7 -0
@@ -50,6 +50,13 @@ void blk_execute_rq_nowait(struct request_queue *q, struct gendisk *bd_disk, {int where = at_head ?ELEVATOR_INSERT_FRONT :ELEVATOR_INSERT_BACK ; +if (unlikely (test_bit (QUEUE_FLAG_DEAD , &q->queue_flags))) { + rq->errors = -ENXIO ; +if (rq->end_io) + rq->end_io (rq, rq->errors); +return ; + } + rq->rq_disk = bd_disk; rq->end_io = done;WARN_ON (irqs_disabled ());
crypto/md5.c +1 -91
100 lines not on this page · raw message
drivers/block/cciss.h +1 -1
@@ -223,7 +223,7 @@ static void SA5_submit_command( ctlr_info_t *h, CommandList_struct *c) h->ctlr, c->busaddr);#endif /* CCISS_DEBUG */ writel (c->busaddr, h->vaddr +SA5_REQUEST_PORT_OFFSET ); -readl (h->vaddr +SA5_REQUEST_PORT_OFFSET ); +readl (h->vaddr +SA5_SCRATCHPAD_OFFSET ); h->commands_outstanding++;if ( h->commands_outstanding > h->max_outstanding) h->max_outstanding = h->commands_outstanding;
drivers/block/loop.c +4 -2
@@ -750,10 +750,10 @@ static ssize_t loop_attr_backing_file_show(struct loop_device *lo, char *buf)ssize_t ret;char *p =NULL ; -mutex_lock (&lo->lo_ctl_mutex); +spin_lock_irq (&lo->lo_lock);if (lo->lo_backing_file) p =d_path (&lo->lo_backing_file->f_path, buf,PAGE_SIZE -1 ); -mutex_unlock (&lo->lo_ctl_mutex); +spin_unlock_irq (&lo->lo_lock);if (IS_ERR_OR_NULL (p)) ret =PTR_ERR (p);
@@ -1007,7 +1007,9 @@ static int loop_clr_fd(struct loop_device *lo, struct block_device *bdev)kthread_stop (lo->lo_thread); +spin_lock_irq (&lo->lo_lock); lo->lo_backing_file =NULL ; +spin_unlock_irq (&lo->lo_lock);loop_release_xfer (lo); lo->transfer =NULL ;
drivers/block/xen-blkfront.c +3 -3
@@ -123,8 +123,8 @@ static DEFINE_SPINLOCK(minor_lock);#define BLKIF_MINOR_EXT (dev) ((dev)&(~EXTENDED))#define EMULATED_HD_DISK_MINOR_OFFSET (0)#define EMULATED_HD_DISK_NAME_OFFSET (EMULATED_HD_DISK_MINOR_OFFSET / 256) -#define EMULATED_SD_DISK_MINOR_OFFSET (EMULATED_HD_DISK_MINOR_OFFSET + (4 * 16)) -#define EMULATED_SD_DISK_NAME_OFFSET (EMULATED_HD_DISK_NAME_OFFSET + 4) +#define EMULATED_SD_DISK_MINOR_OFFSET (0) +#define EMULATED_SD_DISK_NAME_OFFSET (EMULATED_SD_DISK_MINOR_OFFSET / 256)#define DEV_NAME "xvd"/* name in /dev */
@@ -529,7 +529,7 @@ static int xlvbd_alloc_gendisk(blkif_sector_t capacity, minor =BLKIF_MINOR_EXT (info->vdevice); nr_parts =PARTS_PER_EXT_DISK ; offset = minor / nr_parts; -if (xen_hvm_domain () && offset <=EMULATED_HD_DISK_NAME_OFFSET +4 ) +if (xen_hvm_domain () && offset <EMULATED_HD_DISK_NAME_OFFSET +4 )printk (KERN_WARNING "blkfront: vdevice 0x%x might conflict with " "emulated IDE disks,\n\t choose an xvd device name" "from xvde on\n" , info->vdevice);
drivers/char/random.c +8 -326
355 lines not on this page · raw message
drivers/edac/i7core_edac.c +1 -1
@@ -1670,7 +1670,7 @@ static void i7core_mce_output_error(struct mem_ctl_info *mci,char *type, *optype, *err, *msg;unsigned long error = m->status &0x1ff0000l ;u32 optypenum = (m->status >>4 ) &0x07 ; -u32 core_err_cnt = (m->status >>38 ) &&0x7fff ; +u32 core_err_cnt = (m->status >>38 ) &0x7fff ;u32 dimm = (m->misc >>16 ) &0x3 ;u32 channel = (m->misc >>18 ) &0x3 ;u32 syndrome = m->misc >>32 ;
drivers/firewire/core-cdev.c +11 -9
@@ -253,14 +253,11 @@ static int fw_device_op_open(struct inode *inode, struct file *file)init_waitqueue_head (&client->wait);init_waitqueue_head (&client->tx_flush_wait);INIT_LIST_HEAD (&client->phy_receiver_link); +INIT_LIST_HEAD (&client->link);kref_init (&client->kref); file->private_data = client; -mutex_lock (&device->client_list_mutex); -list_add_tail (&client->link, &device->client_list); -mutex_unlock (&device->client_list_mutex); -return nonseekable_open (inode, file); }
@@ -451,15 +448,20 @@ static int ioctl_get_info(struct client *client, union ioctl_arg *arg)if (ret !=0 )return -EFAULT ; +mutex_lock (&client->device->client_list_mutex); + client->bus_reset_closure = a->bus_reset_closure;if (a->bus_reset !=0 ) {fill_bus_reset_event (&bus_reset, client); -if (copy_to_user (u64_to_uptr (a->bus_reset), - &bus_reset,sizeof (bus_reset))) -return -EFAULT ; + ret =copy_to_user (u64_to_uptr (a->bus_reset), + &bus_reset,sizeof (bus_reset)); } +if (ret ==0 &&list_empty (&client->link)) +list_add_tail (&client->link, &client->device->client_list); -return 0 ; +mutex_unlock (&client->device->client_list_mutex); + +return ret ? -EFAULT :0 ; } static int add_client_resource(struct client *client,
@@ -1583,7 +1585,7 @@ static int dispatch_ioctl(struct client *client,if (_IOC_TYPE (cmd) !='#' ||_IOC_NR (cmd) >=ARRAY_SIZE (ioctl_handlers) ||_IOC_SIZE (cmd) >sizeof (buffer)) -return -EINVAL ; +return -ENOTTY ;if (_IOC_DIR (cmd) == _IOC_READ)memset (&buffer,0 ,_IOC_SIZE (cmd));
drivers/firmware/sigma.c +3 -0
@@ -11,6 +11,7 @@#include <linux/firmware.h> #include <linux/kernel.h> #include <linux/i2c.h> +#include <linux/module.h> #include <linux/sigma.h> /* Return: 0==OK, <0==error, =1 ==no more actions */
@@ -113,3 +114,5 @@ int process_sigma_firmware(struct i2c_client *client, const char *name)return ret; }EXPORT_SYMBOL (process_sigma_firmware); + +MODULE_LICENSE ("GPL" );
drivers/gpu/drm/drm_edid.c +18 -6
@@ -127,6 +127,23 @@ static const u8 edid_header[] = { 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00 }; +/* +* Sanity check the header of the base EDID block. Return 8 if the header +* is perfect, down to 0 if it's totally wrong. +*/ +int drm_edid_header_is_valid (const u8 *raw_edid) +{ +int i, score =0 ; + +for (i =0 ; i <sizeof (edid_header); i++) +if (raw_edid[i] == edid_header[i]) + score++; + +return score; +} +EXPORT_SYMBOL (drm_edid_header_is_valid); + +/* * Sanity check the EDID block (base or extension). Return 0 if the block * doesn't check out, or 1 if it's valid.
@@ -139,12 +156,7 @@ drm_edid_block_valid(u8 *raw_edid)struct edid *edid = (struct edid *)raw_edid;if (raw_edid[0 ] ==0x00 ) { -int score =0 ; - -for (i =0 ; i <sizeof (edid_header); i++) -if (raw_edid[i] == edid_header[i]) - score++; - +int score =drm_edid_header_is_valid (raw_edid);if (score ==8 ) ;else if (score >=6 ) {DRM_DEBUG ("Fixing EDID header, your hardware may be failing\n" );
drivers/gpu/drm/i915/i915_dma.c +2 -4
@@ -61,7 +61,6 @@ static void i915_write_hws_pga(struct drm_device *dev)static int i915_init_phys_hws (struct drm_device *dev) {drm_i915_private_t *dev_priv = dev->dev_private; -struct intel_ring_buffer *ring =LP_RING (dev_priv);/* Program Hardware Status Page */ dev_priv->status_page_dmah =
@@ -71,10 +70,9 @@ static int i915_init_phys_hws(struct drm_device *dev)DRM_ERROR ("Can not allocate hardware status page\n" );return -ENOMEM ; } - ring->status_page.page_addr = - (void __force __iomem *)dev_priv->status_page_dmah->vaddr; -memset_io (ring->status_page.page_addr,0 ,PAGE_SIZE ); +memset_io ((void __force __iomem *)dev_priv->status_page_dmah->vaddr, +0 ,PAGE_SIZE );i915_write_hws_pga (dev);
drivers/gpu/drm/i915/i915_irq.c +3 -0
@@ -306,12 +306,15 @@ static void i915_hotplug_work_func(struct work_struct *work)struct drm_mode_config *mode_config = &dev->mode_config;struct intel_encoder *encoder; +mutex_lock (&mode_config->mutex);DRM_DEBUG_KMS ("running encoder hotplug functions\n" );list_for_each_entry (encoder, &mode_config->encoder_list, base.head)if (encoder->hot_plug) encoder->hot_plug (encoder); +mutex_unlock (&mode_config->mutex); +/* Just fire off a uevent and let userspace tell us what to do */ drm_helper_hpd_irq_event (dev); }
drivers/gpu/drm/i915/intel_display.c +6 -2
@@ -2699,14 +2699,18 @@ static void ironlake_crtc_enable(struct drm_crtc *crtc)I915_WRITE (PF_WIN_SZ (pipe), dev_priv->pch_pf_size); } +/* +* On ILK+ LUT must be loaded before the pipe is running but with +* clocks enabled +*/ +intel_crtc_load_lut (crtc); +intel_enable_pipe (dev_priv, pipe, is_pch_port);intel_enable_plane (dev_priv, plane, pipe);if (is_pch_port)ironlake_pch_enable (crtc); -intel_crtc_load_lut (crtc); -mutex_lock (&dev->struct_mutex);intel_update_fbc (dev);mutex_unlock (&dev->struct_mutex);
drivers/gpu/drm/i915/intel_panel.c +4 -0
@@ -83,11 +83,15 @@ intel_pch_panel_fitting(struct drm_device *dev,u32 scaled_height = mode->hdisplay * adjusted_mode->vdisplay;if (scaled_width > scaled_height) {/* pillar */ width = scaled_height / mode->vdisplay; +if (width &1 ) + width++; x = (adjusted_mode->hdisplay - width +1 ) /2 ; y =0 ; height = adjusted_mode->vdisplay; }else if (scaled_width < scaled_height) {/* letter */ height = scaled_width / mode->hdisplay; +if (height &1 ) + height++; y = (adjusted_mode->vdisplay - height +1 ) /2 ; x =0 ; width = adjusted_mode->hdisplay;
drivers/gpu/drm/i915/intel_ringbuffer.c +3 -0
@@ -1319,6 +1319,9 @@ int intel_render_ring_init_dri(struct drm_device *dev, u64 start, u32 size) ring->get_seqno = pc_render_get_seqno; } +if (!I915_NEED_GFX_HWS (dev)) + ring->status_page.page_addr = dev_priv->status_page_dmah->vaddr; + ring->dev = dev;INIT_LIST_HEAD (&ring->active_list);INIT_LIST_HEAD (&ring->request_list);
drivers/gpu/drm/radeon/atombios_dp.c +30 -4
@@ -613,6 +613,18 @@ static bool radeon_dp_get_link_status(struct radeon_connector *radeon_connector,return true; } +bool radeon_dp_needs_link_train (struct radeon_connector *radeon_connector) +{ +u8 link_status[DP_LINK_STATUS_SIZE ]; +struct radeon_connector_atom_dig *dig = radeon_connector->con_priv; + +if (!radeon_dp_get_link_status (radeon_connector, link_status)) +return false; +if (dp_channel_eq_ok (link_status, dig->dp_lane_count)) +return false; +return true; +} +struct radeon_dp_link_train_info {struct radeon_device *rdev;struct drm_encoder *encoder;
@@ -627,6 +639,7 @@ struct radeon_dp_link_train_info {u8 train_set[4 ];u8 link_status[DP_LINK_STATUS_SIZE ];u8 tries; +bool use_dpencoder; };static void radeon_dp_update_vs_emph (struct radeon_dp_link_train_info *dp_info)
@@ -646,7 +659,7 @@ static void radeon_dp_set_tp(struct radeon_dp_link_train_info *dp_info, int tp)int rtp =0 ;/* set training pattern on the source */ -if (ASIC_IS_DCE4 (dp_info->rdev)) { +if (ASIC_IS_DCE4 (dp_info->rdev) || !dp_info->use_dpencoder) {switch (tp) {case DP_TRAINING_PATTERN_1 : rtp =ATOM_ENCODER_CMD_DP_LINK_TRAINING_PATTERN1 ;
@@ -706,7 +719,7 @@ static int radeon_dp_link_train_init(struct radeon_dp_link_train_info *dp_info)radeon_write_dpcd_reg (dp_info->radeon_connector,DP_LINK_BW_SET , tmp);/* start training on the source */ -if (ASIC_IS_DCE4 (dp_info->rdev)) +if (ASIC_IS_DCE4 (dp_info->rdev) || !dp_info->use_dpencoder)atombios_dig_encoder_setup (dp_info->encoder,ATOM_ENCODER_CMD_DP_LINK_TRAINING_START ,0 );else
@@ -731,7 +744,7 @@ static int radeon_dp_link_train_finish(struct radeon_dp_link_train_info *dp_info DP_TRAINING_PATTERN_DISABLE);/* disable the training pattern on the source */ -if (ASIC_IS_DCE4 (dp_info->rdev)) +if (ASIC_IS_DCE4 (dp_info->rdev) || !dp_info->use_dpencoder)atombios_dig_encoder_setup (dp_info->encoder,ATOM_ENCODER_CMD_DP_LINK_TRAINING_COMPLETE ,0 );else
@@ -869,7 +882,8 @@ void radeon_dp_link_train(struct drm_encoder *encoder,struct radeon_connector *radeon_connector;struct radeon_connector_atom_dig *dig_connector;struct radeon_dp_link_train_info dp_info; -u8 tmp; +int index; +u8 tmp, frev, crev;if (!radeon_encoder->enc_priv)return ;
@@ -884,6 +898,18 @@ void radeon_dp_link_train(struct drm_encoder *encoder, (dig_connector->dp_sink_type != CONNECTOR_OBJECT_ID_eDP)) return; +/* DPEncoderService newer than 1.1 can't program properly the +* training pattern. When facing such version use the +* DIGXEncoderControl (X== 1 | 2) +*/ + dp_info.use_dpencoder = true; + index =GetIndexIntoMasterTable (COMMAND , DPEncoderService); +if (atom_parse_cmd_header (rdev->mode_info.atom_context, index, &frev, &crev)) { +if (crev >1 ) { + dp_info.use_dpencoder = false; + } + } + dp_info.enc_id =0 ;if (dig->dig_encoder) dp_info.enc_id |=ATOM_DP_CONFIG_DIG2_ENCODER ;
drivers/gpu/drm/radeon/radeon_combios.c +2 -1
@@ -779,7 +779,8 @@ void radeon_combios_i2c_init(struct radeon_device *rdev) } } } - }else if (rdev->family >=CHIP_R200 ) { + }else if ((rdev->family ==CHIP_R200 ) || + (rdev->family >=CHIP_R300 )) {/* 0x68 */ i2c =combios_setup_i2c_bus (rdev,DDC_MONID ,0 ,0 ); rdev->i2c_bus[3 ] =radeon_i2c_create (dev, &i2c,"MONID" );
drivers/gpu/drm/radeon/radeon_connectors.c +70 -10
99 lines not on this page · raw message
drivers/gpu/drm/radeon/radeon_display.c +9 -0
Lines of this file are not shown. View the raw message.
drivers/gpu/drm/radeon/radeon_encoders.c +3 -0
Lines of this file are not shown. View the raw message.
drivers/net/bonding/bond_sysfs.c +71 -62
133 lines not on this page · raw message
drivers/net/wireless/ath/ath9k/ar9002_hw.c +1 -5
Lines of this file are not shown. View the raw message.
drivers/net/wireless/ath/ath9k/ar9003_eeprom.c +3 -3
Lines of this file are not shown. View the raw message.
drivers/net/wireless/ath/ath9k/ar9003_hw.c +1 -5
Lines of this file are not shown. View the raw message.
drivers/net/wireless/ath/ath9k/ar9003_mac.c +1 -2
Lines of this file are not shown. View the raw message.
drivers/net/wireless/ath/ath9k/ar9003_phy.h +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/hostap/hostap_main.c +1 -0
Lines of this file are not shown. View the raw message.
drivers/net/wireless/iwlegacy/iwl-3945.c +5 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/iwlegacy/iwl-4965.c +6 -2
Lines of this file are not shown. View the raw message.
drivers/net/wireless/iwlwifi/iwl-5000.c +1 -0
Lines of this file are not shown. View the raw message.
drivers/net/wireless/iwlwifi/iwl-core.h +2 -0
Lines of this file are not shown. View the raw message.
drivers/net/wireless/iwlwifi/iwl-power.c +2 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/rt2x00/rt2800lib.c +1 -2
Lines of this file are not shown. View the raw message.
drivers/net/wireless/rt2x00/rt2800pci.c +1 -0
Lines of this file are not shown. View the raw message.
drivers/net/wireless/rt2x00/rt2x00mac.c +3 -2
Lines of this file are not shown. View the raw message.
drivers/net/wireless/rt2x00/rt2x00usb.c +7 -10
Lines of this file are not shown. View the raw message.
drivers/net/wireless/rtlwifi/rtl8192cu/rf.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/rtc/interface.c +38 -17
55 lines not on this page · raw message
drivers/scsi/mpt2sas/mpt2sas_base.c +25 -40
65 lines not on this page · raw message
drivers/scsi/mpt2sas/mpt2sas_base.h +50 -3
53 lines not on this page · raw message
drivers/scsi/mpt2sas/mpt2sas_transport.c +9 -15
Lines of this file are not shown. View the raw message.
drivers/scsi/sr.c +42 -4
46 lines not on this page · raw message
drivers/staging/ath6kl/os/linux/ar6000_drv.c +35 -15
50 lines not on this page · raw message
drivers/staging/ath6kl/os/linux/cfg80211.c +18 -13
Lines of this file are not shown. View the raw message.
drivers/staging/ath6kl/os/linux/include/ar6000_drv.h +9 -0
Lines of this file are not shown. View the raw message.
drivers/staging/brcm80211/brcmsmac/wl_mac80211.c +0 -5
Lines of this file are not shown. View the raw message.
drivers/staging/rtl8192u/r819xU_firmware.c +3 -6
Lines of this file are not shown. View the raw message.
drivers/usb/host/ehci-q.c +42 -43
85 lines not on this page · raw message
fs/ecryptfs/keystore.c +25 -22
47 lines not on this page · raw message
fs/nfs/dir.c +33 -23
56 lines not on this page · raw message
fs/nfs/pnfs.c +33 -30
63 lines not on this page · raw message
fs/nfsd/nfs4state.c +26 -40
66 lines not on this page · raw message
kernel/futex.c +44 -14
58 lines not on this page · raw message
kernel/trace/trace_events.c +95 -18
113 lines not on this page · raw message
lib/md5.c new file +95 -0
95 lines not on this page · raw message
mm/memory.c +57 -1
58 lines not on this page · raw message
net/core/secure_seq.c new file +184 -0
184 lines not on this page · raw message
net/ipv4/netfilter/nf_nat_proto_common.c +1 -0
Lines of this file are not shown. View the raw message.
net/socket.c +40 -33
73 lines not on this page · raw message
sound/soc/codecs/sgtl5000.c +35 -93
128 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Part of the diff is not shown here. View the raw message.