svn commit: r291419 - in head/sys: i386/conf modules pc98/conf
Author: kib Date: Sat Nov 28 08:31:32 2015 New Revision: 291419 URL: https://svnweb.freebsd.org/changeset/base/291419 Log: Disconnect iBCS2 emulator from the build. The ibcs2 option, the build glue and the sources are not removed for now. Discussed with: emaste Sponsored by: The FreeBSD Foundation Modified: head/sys/i386/conf/NOTES head/sys/modules/Makefile head/sys/pc98/conf/NOTES Modified: head/sys/i386/conf/NOTES == --- head/sys/i386/conf/NOTESSat Nov 28 06:50:09 2015(r291418) +++ head/sys/i386/conf/NOTESSat Nov 28 08:31:32 2015(r291419) @@ -989,7 +989,7 @@ options NKPT=31 # ABI Emulation # Enable iBCS2 runtime support for SCO and ISC binaries -optionsIBCS2 +#options IBCS2 # Emulate spx device for client side of SVR3 local X interface optionsSPX_HACK Modified: head/sys/modules/Makefile == --- head/sys/modules/Makefile Sat Nov 28 06:50:09 2015(r291418) +++ head/sys/modules/Makefile Sat Nov 28 08:31:32 2015(r291419) @@ -682,7 +682,7 @@ _cp=cp _elink=elink _glxiic= glxiic _glxsb=glxsb -_ibcs2=ibcs2 +#_ibcs2= ibcs2 _ie= ie _mse= mse _ncr= ncr Modified: head/sys/pc98/conf/NOTES == --- head/sys/pc98/conf/NOTESSat Nov 28 06:50:09 2015(r291418) +++ head/sys/pc98/conf/NOTESSat Nov 28 08:31:32 2015(r291419) @@ -506,7 +506,7 @@ options KVA_PAGES=260 # ABI Emulation # Enable iBCS2 runtime support for SCO and ISC binaries -optionsIBCS2 +#options IBCS2 # Emulate spx device for client side of SVR3 local X interface optionsSPX_HACK ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291424 - head/sys/arm/arm
Author: mmel Date: Sat Nov 28 12:09:36 2015 New Revision: 291424 URL: https://svnweb.freebsd.org/changeset/base/291424 Log: ARM: Cumulative fixes for GIC - fix detection of interrupt root controller - allow (but warn) unsupported configuration bits - dont send EOI for spurious interrupts - print more informations for spurious interrupts - use device_printf() where appropriate Reviewed by: ian (earlier version) Approved by: kib (mentor) Modified: head/sys/arm/arm/gic.c Modified: head/sys/arm/arm/gic.c == --- head/sys/arm/arm/gic.c Sat Nov 28 09:50:52 2015(r291423) +++ head/sys/arm/arm/gic.c Sat Nov 28 12:09:36 2015(r291424) @@ -68,6 +68,8 @@ __FBSDID("$FreeBSD$"); #include "pic_if.h" #endif +#define GIC_DEBUG_SPURIOUS + /* We are using GICv2 register naming */ /* Distributor Registers */ @@ -135,6 +137,9 @@ struct arm_gic_softc { uint8_t ver; struct mtx mutex; uint32_tnirqs; +#ifdef GIC_DEBUG_SPURIOUS + uint32_tlast_irq[MAXCPU]; +#endif }; static struct resource_spec arm_gic_spec[] = { @@ -287,7 +292,7 @@ arm_gic_init_secondary(device_t dev) } #endif /* ARM_INTRNG */ #endif /* SMP */ - + #ifndef ARM_INTRNG int gic_decode_fdt(phandle_t iparent, pcell_t *intr, int *interrupt, @@ -335,11 +340,10 @@ gic_decode_fdt(phandle_t iparent, pcell_ */ if (fdt32_to_cpu(intr[2]) & 0x0a) { printf("unsupported trigger/polarity configuration " - "0x%2x\n", fdt32_to_cpu(intr[2]) & 0x0f); - return (ENOTSUP); + "0x%02x\n", fdt32_to_cpu(intr[2]) & 0x0f); } *pol = INTR_POLARITY_CONFORM; - if (fdt32_to_cpu(intr[2]) & 0x01) + if (fdt32_to_cpu(intr[2]) & 0x03) *trig = INTR_TRIGGER_EDGE; else *trig = INTR_TRIGGER_LEVEL; @@ -367,6 +371,7 @@ arm_gic_attach(device_t dev) int i; uint32_ticciidr; #ifdef ARM_INTRNG + phandle_t pxref; intptr_txref = gic_xref(dev); #endif @@ -456,7 +461,9 @@ arm_gic_attach(device_t dev) goto cleanup; } - if (sc->gic_res[2] == NULL) { + i = OF_getencprop(ofw_bus_get_node(dev), "interrupt-parent", + , sizeof(pxref)); + if (i > 0 && xref == pxref) { if (arm_pic_claim_root(dev, xref, arm_gic_intr, sc, GIC_LAST_SGI - GIC_FIRST_SGI + 1) != 0) { device_printf(dev, "could not set PIC as a root\n"); @@ -472,6 +479,7 @@ arm_gic_attach(device_t dev) } } + OF_device_register_xref(xref, dev); return (0); cleanup: @@ -516,8 +524,11 @@ arm_gic_intr(void *arg) */ if (irq >= sc->nirqs) { - device_printf(sc->gic_dev, "Spurious interrupt detected\n"); - gic_c_write_4(sc, GICC_EOIR, irq_active_reg); +#ifdef GIC_DEBUG_SPURIOUS + device_printf(sc->gic_dev, + "Spurious interrupt detected: last irq: %d on CPU%d\n", + sc->last_irq[PCPU_GET(cpuid)], PCPU_GET(cpuid)); +#endif return (FILTER_HANDLED); } @@ -542,12 +553,16 @@ dispatch_irq: arm_ipi_dispatch(isrc, tf); goto next_irq; #else - printf("SGI %u on UP system detected\n", irq - GIC_FIRST_SGI); + device_printf(sc->gic_dev, "SGI %u on UP system detected\n", + irq - GIC_FIRST_SGI); gic_c_write_4(sc, GICC_EOIR, irq_active_reg); goto next_irq; #endif } +#ifdef GIC_DEBUG_SPURIOUS + sc->last_irq[PCPU_GET(cpuid)] = irq; +#endif if (isrc->isrc_trig == INTR_TRIGGER_EDGE) gic_c_write_4(sc, GICC_EOIR, irq_active_reg); @@ -729,12 +744,12 @@ gic_map_fdt(struct arm_gic_softc *sc, st */ tripol = isrc->isrc_cells[2]; if (tripol & 0x0a) { - printf("unsupported trigger/polarity configuration " - "0x%2x\n", tripol & 0x0f); - return (ENOTSUP); + device_printf(sc->gic_dev, + "unsupported trigger/polarity configuration " + "0x%02x\n", tripol & 0x0f); } pol = INTR_POLARITY_CONFORM; - if (tripol & 0x01) + if (tripol & 0x03) trig = INTR_TRIGGER_EDGE; else trig = INTR_TRIGGER_LEVEL; @@ -911,7 +926,8 @@ arm_gic_next_irq(struct arm_gic_softc *s if (active_irq == 0x3FF) { if (last_irq ==
svn commit: r291426 - head/sys/arm/include
Author: mmel Date: Sat Nov 28 12:12:28 2015 New Revision: 291426 URL: https://svnweb.freebsd.org/changeset/base/291426 Log: ARM: Implement atomic_swap_int(9). It's used in DRM2 code. Approved by: kib (mentor) Modified: head/sys/arm/include/atomic-v4.h head/sys/arm/include/atomic-v6.h head/sys/arm/include/atomic.h Modified: head/sys/arm/include/atomic-v4.h == --- head/sys/arm/include/atomic-v4.hSat Nov 28 12:11:44 2015 (r291425) +++ head/sys/arm/include/atomic-v4.hSat Nov 28 12:12:28 2015 (r291426) @@ -363,6 +363,13 @@ atomic_readandclear_32(volatile u_int32_ return (__swp(0, p)); } +static __inline uint32_t +atomic_swap_32(volatile u_int32_t *p, u_int32_t v) +{ + + return (__swp(v, p)); +} + #define atomic_cmpset_rel_32 atomic_cmpset_32 #define atomic_cmpset_acq_32 atomic_cmpset_32 #define atomic_set_rel_32 atomic_set_32 Modified: head/sys/arm/include/atomic-v6.h == --- head/sys/arm/include/atomic-v6.hSat Nov 28 12:11:44 2015 (r291425) +++ head/sys/arm/include/atomic-v6.hSat Nov 28 12:12:28 2015 (r291426) @@ -641,6 +641,25 @@ atomic_testandset_64(volatile uint64_t * return (atomic_testandset_32(p32, v)); } +static __inline uint32_t +atomic_swap_32(volatile uint32_t *p, uint32_t v) +{ + uint32_t ret, exflag; + + __asm __volatile( + "1: ldrex %[ret], [%[ptr]]\n" + " strex %[exf], %[val], [%[ptr]]\n" + " teq %[exf], #0 \n" + " it ne \n" + " bne 1b \n" + : [ret] "=r" (ret), + [exf] "=" (exflag) + : [val] "r" (v), + [ptr] "r" (p) + : "cc", "memory"); + return (ret); +} + #undef ATOMIC_ACQ_REL #undef ATOMIC_ACQ_REL_LONG Modified: head/sys/arm/include/atomic.h == --- head/sys/arm/include/atomic.h Sat Nov 28 12:11:44 2015 (r291425) +++ head/sys/arm/include/atomic.h Sat Nov 28 12:12:28 2015 (r291426) @@ -109,5 +109,6 @@ atomic_store_long(volatile u_long *dst, #define atomic_readandclear_intatomic_readandclear_32 #define atomic_load_acq_intatomic_load_acq_32 #define atomic_store_rel_int atomic_store_rel_32 +#define atomic_swap_intatomic_swap_32 #endif /* _MACHINE_ATOMIC_H_ */ ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r291419 - in head/sys: i386/conf modules pc98/conf
On Sat, Nov 28, 2015 at 08:31:32AM +, Konstantin Belousov wrote: > Author: kib > Date: Sat Nov 28 08:31:32 2015 > New Revision: 291419 > URL: https://svnweb.freebsd.org/changeset/base/291419 > > Log: > Disconnect iBCS2 emulator from the build. The ibcs2 option, the build > glue and the sources are not removed for now. > > Discussed with: emaste > Sponsored by: The FreeBSD Foundation By the next commit, the iBCS2 build would be broken. I kept the build glue and iBCS2 option in the conf/ to not make large churn if the build is going to be restored. If somebody has option IBCS2 in the kernel config, it has to be removed. I have pending patches which both restore the iBCS2 emulator build and fix issues with the signal frame layout for the SCO binaries. These patches are not committable right now for non-technical reasons. Either the reasons will be cleared, which would allow the commit and re-connection of the iBCS2 to the build, or the emulator will be removed from the tree since the code cannot be maintained. ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
[kostik...@gmail.com: Re: svn commit: r291419 - in head/sys: i386/conf modules pc98/conf]
[Resend to include all relevant addresses] - Forwarded message from Konstantin Belousov- Date: Sat, 28 Nov 2015 10:34:01 +0200 From: Konstantin Belousov To: svn-src-head@freebsd.org Subject: Re: svn commit: r291419 - in head/sys: i386/conf modules pc98/conf On Sat, Nov 28, 2015 at 08:31:32AM +, Konstantin Belousov wrote: > Author: kib > Date: Sat Nov 28 08:31:32 2015 > New Revision: 291419 > URL: https://svnweb.freebsd.org/changeset/base/291419 > > Log: > Disconnect iBCS2 emulator from the build. The ibcs2 option, the build > glue and the sources are not removed for now. > > Discussed with: emaste > Sponsored by: The FreeBSD Foundation By the next commit, the iBCS2 build would be broken. I kept the build glue and iBCS2 option in the conf/ to not make large churn if the build is going to be restored. If somebody has option IBCS2 in the kernel config, it has to be removed. I have pending patches which both restore the iBCS2 emulator build and fix issues with the signal frame layout for the SCO binaries. These patches are not committable right now for non-technical reasons. Either the reasons will be cleared, which would allow the commit and re-connection of the iBCS2 to the build, or the emulator will be removed from the tree since the code cannot be maintained. ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291420 - in head/sys: amd64/amd64 amd64/linux amd64/linux32 arm/arm arm64/arm64 compat/ia32 compat/svr4 i386/i386 i386/linux kern mips/mips powerpc/powerpc sparc64/sparc64 sys
Author: kib Date: Sat Nov 28 08:49:07 2015 New Revision: 291420 URL: https://svnweb.freebsd.org/changeset/base/291420 Log: Remove sv_prepsyscall, sv_sigsize and sv_sigtbl members of the struct sysent. sv_prepsyscall is unused. sv_sigsize and sv_sigtbl translate signal number from the FreeBSD namespace into the ABI domain. It is only utilized on i386 for iBCS2 binaries. The issue with this approach is that signals for iBCS2 were delivered with the FreeBSD signal frame layout, which does not follow iBCS2. The same note is true for any other potential user if sv_sigtbl. In other words, if ABI needs signal number translation, it really needs custom sv_sendsig method instead. Sponsored by: The FreeBSD Foundation Modified: head/sys/amd64/amd64/elf_machdep.c head/sys/amd64/linux/linux_sysvec.c head/sys/amd64/linux32/linux32_sysvec.c head/sys/arm/arm/elf_machdep.c head/sys/arm64/arm64/elf_machdep.c head/sys/compat/ia32/ia32_sysvec.c head/sys/compat/svr4/svr4_sysvec.c head/sys/i386/i386/elf_machdep.c head/sys/i386/i386/machdep.c head/sys/i386/linux/linux_sysvec.c head/sys/kern/imgact_aout.c head/sys/kern/init_main.c head/sys/mips/mips/elf_machdep.c head/sys/mips/mips/freebsd32_machdep.c head/sys/powerpc/powerpc/elf32_machdep.c head/sys/powerpc/powerpc/elf64_machdep.c head/sys/sparc64/sparc64/elf_machdep.c head/sys/sys/sysent.h Modified: head/sys/amd64/amd64/elf_machdep.c == --- head/sys/amd64/amd64/elf_machdep.c Sat Nov 28 08:31:32 2015 (r291419) +++ head/sys/amd64/amd64/elf_machdep.c Sat Nov 28 08:49:07 2015 (r291420) @@ -51,8 +51,6 @@ struct sysentvec elf64_freebsd_sysvec = .sv_size= SYS_MAXSYSCALL, .sv_table = sysent, .sv_mask= 0, - .sv_sigsize = 0, - .sv_sigtbl = NULL, .sv_errsize = 0, .sv_errtbl = NULL, .sv_transtrap = NULL, @@ -60,7 +58,6 @@ struct sysentvec elf64_freebsd_sysvec = .sv_sendsig = sendsig, .sv_sigcode = sigcode, .sv_szsigcode = , - .sv_prepsyscall = NULL, .sv_name= "FreeBSD ELF64", .sv_coredump= __elfN(coredump), .sv_imgact_try = NULL, Modified: head/sys/amd64/linux/linux_sysvec.c == --- head/sys/amd64/linux/linux_sysvec.c Sat Nov 28 08:31:32 2015 (r291419) +++ head/sys/amd64/linux/linux_sysvec.c Sat Nov 28 08:49:07 2015 (r291420) @@ -750,8 +750,6 @@ struct sysentvec elf_linux_sysvec = { .sv_size= LINUX_SYS_MAXSYSCALL, .sv_table = linux_sysent, .sv_mask= 0, - .sv_sigsize = 0, - .sv_sigtbl = NULL, .sv_errsize = ELAST + 1, .sv_errtbl = bsd_to_linux_errno, .sv_transtrap = translate_traps, @@ -759,7 +757,6 @@ struct sysentvec elf_linux_sysvec = { .sv_sendsig = linux_rt_sendsig, .sv_sigcode = &_binary_linux_locore_o_start, .sv_szsigcode = _szsigcode, - .sv_prepsyscall = NULL, .sv_name= "Linux ELF64", .sv_coredump= elf64_coredump, .sv_imgact_try = exec_linux_imgact_try, Modified: head/sys/amd64/linux32/linux32_sysvec.c == --- head/sys/amd64/linux32/linux32_sysvec.c Sat Nov 28 08:31:32 2015 (r291419) +++ head/sys/amd64/linux32/linux32_sysvec.c Sat Nov 28 08:49:07 2015 (r291420) @@ -1011,8 +1011,6 @@ struct sysentvec elf_linux_sysvec = { .sv_size= LINUX32_SYS_MAXSYSCALL, .sv_table = linux32_sysent, .sv_mask= 0, - .sv_sigsize = 0, - .sv_sigtbl = NULL, .sv_errsize = ELAST + 1, .sv_errtbl = bsd_to_linux_errno, .sv_transtrap = translate_traps, @@ -1020,7 +1018,6 @@ struct sysentvec elf_linux_sysvec = { .sv_sendsig = linux_sendsig, .sv_sigcode = &_binary_linux32_locore_o_start, .sv_szsigcode = _szsigcode, - .sv_prepsyscall = NULL, .sv_name= "Linux ELF32", .sv_coredump= elf32_coredump, .sv_imgact_try = exec_linux_imgact_try, Modified: head/sys/arm/arm/elf_machdep.c == --- head/sys/arm/arm/elf_machdep.c Sat Nov 28 08:31:32 2015 (r291419) +++ head/sys/arm/arm/elf_machdep.c Sat Nov 28 08:49:07 2015 (r291420) @@ -52,8 +52,6 @@ struct sysentvec elf32_freebsd_sysvec = .sv_size= SYS_MAXSYSCALL, .sv_table = sysent, .sv_mask= 0, - .sv_sigsize = 0, - .sv_sigtbl = NULL, .sv_errsize = 0, .sv_errtbl = NULL, .sv_transtrap = NULL, @@
svn commit: r291425 - in head/sys/arm: arm include
Author: mmel Date: Sat Nov 28 12:11:44 2015 New Revision: 291425 URL: https://svnweb.freebsd.org/changeset/base/291425 Log: ARM: Add support for new KRAIT 300 CPU revision. Approved by: kib (mentor) Modified: head/sys/arm/arm/cpufunc.c head/sys/arm/arm/identcpu.c head/sys/arm/include/armreg.h Modified: head/sys/arm/arm/cpufunc.c == --- head/sys/arm/arm/cpufunc.c Sat Nov 28 12:09:36 2015(r291424) +++ head/sys/arm/arm/cpufunc.c Sat Nov 28 12:11:44 2015(r291425) @@ -910,7 +910,8 @@ set_cpufuncs() cputype == CPU_ID_CORTEXA15R1 || cputype == CPU_ID_CORTEXA15R2 || cputype == CPU_ID_CORTEXA15R3 || - cputype == CPU_ID_KRAIT ) { + cputype == CPU_ID_KRAIT300R0 || + cputype == CPU_ID_KRAIT300R1 ) { cpufuncs = cortexa_cpufuncs; cpu_reset_needs_v4_MMU_disable = 1; /* V4 or higher */ get_cachetype_cp15(); Modified: head/sys/arm/arm/identcpu.c == --- head/sys/arm/arm/identcpu.c Sat Nov 28 12:09:36 2015(r291424) +++ head/sys/arm/arm/identcpu.c Sat Nov 28 12:11:44 2015(r291425) @@ -197,7 +197,9 @@ const struct cpuidtab cpuids[] = { generic_steppings }, { CPU_ID_CORTEXA15R3, CPU_CLASS_CORTEXA, "Cortex A15-r3", generic_steppings }, - { CPU_ID_KRAIT, CPU_CLASS_KRAIT,"Krait", + { CPU_ID_KRAIT300R0,CPU_CLASS_KRAIT,"Krait 300-r0", + generic_steppings }, + { CPU_ID_KRAIT300R1,CPU_CLASS_KRAIT,"Krait 300-r1", generic_steppings }, { CPU_ID_80200, CPU_CLASS_XSCALE, "i80200", Modified: head/sys/arm/include/armreg.h == --- head/sys/arm/include/armreg.h Sat Nov 28 12:09:36 2015 (r291424) +++ head/sys/arm/include/armreg.h Sat Nov 28 12:11:44 2015 (r291425) @@ -139,7 +139,9 @@ #define CPU_ID_CORTEXA15R1 0x411fc0f0 #define CPU_ID_CORTEXA15R2 0x412fc0f0 #define CPU_ID_CORTEXA15R3 0x413fc0f0 -#defineCPU_ID_KRAIT0x510f06f0 /* Snapdragon S4 Pro/APQ8064 */ +#defineCPU_ID_KRAIT300R0 0x510f06f0 /* Snapdragon S4 Pro/APQ8064 */ +#defineCPU_ID_KRAIT300R1 0x511f06f0 + #defineCPU_ID_TI925T 0x54029250 #define CPU_ID_MV88FR131 0x56251310 /* Marvell Feroceon 88FR131 Core */ #define CPU_ID_MV88FR331 0x56153310 /* Marvell Feroceon 88FR331 Core */ ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291427 - head/sys/dev/ahci
Author: mmel Date: Sat Nov 28 14:30:42 2015 New Revision: 291427 URL: https://svnweb.freebsd.org/changeset/base/291427 Log: AHCI: Use bus_dmamap_sync(9) when accessing DMA buffers. Reviewed by: mav Approved by: kib (mentor) Differential Revision: https://reviews.freebsd.org/D4240 Modified: head/sys/dev/ahci/ahci.c Modified: head/sys/dev/ahci/ahci.c == --- head/sys/dev/ahci/ahci.cSat Nov 28 12:12:28 2015(r291426) +++ head/sys/dev/ahci/ahci.cSat Nov 28 14:30:42 2015(r291427) @@ -1606,10 +1606,15 @@ ahci_execute_transaction(struct ahci_slo if ((ch->quirks & AHCI_Q_NOBSYRES) == 0 && (ch->quirks & AHCI_Q_ATI_PMP_BUG) == 0 && softreset == 2 && et == AHCI_ERR_NONE) { - while ((val = fis[2]) & ATA_S_BUSY) { - DELAY(10); - if (count++ >= timeout) + for ( ; count < timeout; count++) { + bus_dmamap_sync(ch->dma.rfis_tag, + ch->dma.rfis_map, BUS_DMASYNC_POSTREAD); + val = fis[2]; + bus_dmamap_sync(ch->dma.rfis_tag, + ch->dma.rfis_map, BUS_DMASYNC_PREREAD); + if ((val & ATA_S_BUSY) == 0) break; + DELAY(10); } } ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291431 - head/sys/dev/drm2/i915
Author: dumbbell Date: Sat Nov 28 17:38:27 2015 New Revision: 291431 URL: https://svnweb.freebsd.org/changeset/base/291431 Log: drm/i915: Reduce diff with Linux 3.8 There is no functional change. The goal is to ease the future update to Linux 3.8's i915 driver. MFC after:2 months Modified: head/sys/dev/drm2/i915/i915_drm.h Modified: head/sys/dev/drm2/i915/i915_drm.h == --- head/sys/dev/drm2/i915/i915_drm.h Sat Nov 28 17:37:41 2015 (r291430) +++ head/sys/dev/drm2/i915/i915_drm.h Sat Nov 28 17:38:27 2015 (r291431) @@ -133,10 +133,10 @@ typedef struct _drm_i915_sarea { * over the lifetime of the client, though it doesn't in our current * implementation. */ - unsigned int front_bo_handle; - unsigned int back_bo_handle; - unsigned int third_bo_handle; - unsigned int depth_bo_handle; + __u32 front_bo_handle; + __u32 back_bo_handle; + __u32 third_bo_handle; + __u32 depth_bo_handle; } drm_i915_sarea_t; /* due to userspace building against these headers we need some compat here */ @@ -421,7 +421,7 @@ typedef struct drm_i915_mmio { } drm_i915_mmio_t; typedef struct drm_i915_hws_addr { - uint64_t addr; + __u64 addr; } drm_i915_hws_addr_t; /* @@ -461,12 +461,12 @@ struct drm_i915_gem_init { * Beginning offset in the GTT to be managed by the DRM memory * manager. */ - uint64_t gtt_start; + __u64 gtt_start; /** * Ending offset in the GTT to be managed by the DRM memory * manager. */ - uint64_t gtt_end; + __u64 gtt_end; }; struct drm_i915_gem_create { @@ -475,82 +475,82 @@ struct drm_i915_gem_create { * * The (page-aligned) allocated size for the object will be returned. */ - uint64_t size; + __u64 size; /** * Returned handle for the object. * * Object handles are nonzero. */ - uint32_t handle; - uint32_t pad; + __u32 handle; + __u32 pad; }; struct drm_i915_gem_pread { /** Handle for the object being read. */ - uint32_t handle; - uint32_t pad; + __u32 handle; + __u32 pad; /** Offset into the object to read from */ - uint64_t offset; + __u64 offset; /** Length of data to read */ - uint64_t size; + __u64 size; /** Pointer to write the data into. */ - uint64_t data_ptr; /* void *, but pointers are not 32/64 compatible */ + __u64 data_ptr; /* void *, but pointers are not 32/64 compatible */ }; struct drm_i915_gem_pwrite { /** Handle for the object being written to. */ - uint32_t handle; - uint32_t pad; + __u32 handle; + __u32 pad; /** Offset into the object to write to */ - uint64_t offset; + __u64 offset; /** Length of data to write */ - uint64_t size; + __u64 size; /** Pointer to read the data from. */ - uint64_t data_ptr; /* void *, but pointers are not 32/64 compatible */ + __u64 data_ptr; /* void *, but pointers are not 32/64 compatible */ }; struct drm_i915_gem_mmap { /** Handle for the object being mapped. */ - uint32_t handle; - uint32_t pad; + __u32 handle; + __u32 pad; /** Offset in the object to map. */ - uint64_t offset; + __u64 offset; /** * Length of data to map. * * The value will be page-aligned. */ - uint64_t size; + __u64 size; /** Returned pointer the data was mapped at */ - uint64_t addr_ptr; /* void *, but pointers are not 32/64 compatible */ + __u64 addr_ptr; /* void *, but pointers are not 32/64 compatible */ }; struct drm_i915_gem_mmap_gtt { /** Handle for the object being mapped. */ - uint32_t handle; - uint32_t pad; + __u32 handle; + __u32 pad; /** * Fake offset to use for subsequent mmap call * * This is a fixed-size type for 32/64 compatibility. */ - uint64_t offset; + __u64 offset; }; struct drm_i915_gem_set_domain { /** Handle for the object */ - uint32_t handle; + __u32 handle; /** New read domains */ - uint32_t read_domains; + __u32 read_domains; /** New write domain */ - uint32_t write_domain; + __u32 write_domain; }; struct drm_i915_gem_sw_finish { /** Handle for the object */ - uint32_t handle; + __u32 handle; }; struct drm_i915_gem_relocation_entry { @@ -562,16 +562,16 @@ struct drm_i915_gem_relocation_entry { * a relocation list for state buffers and not re-write it per * exec using the buffer. */ - uint32_t target_handle; +
svn commit: r291430 - head/sys/dev/drm2/i915
Author: dumbbell Date: Sat Nov 28 17:37:41 2015 New Revision: 291430 URL: https://svnweb.freebsd.org/changeset/base/291430 Log: drm/i915: Further reduce the diff in i915_dma.c MFC after:2 months Modified: head/sys/dev/drm2/i915/i915_dma.c Modified: head/sys/dev/drm2/i915/i915_dma.c == --- head/sys/dev/drm2/i915/i915_dma.c Sat Nov 28 17:26:46 2015 (r291429) +++ head/sys/dev/drm2/i915/i915_dma.c Sat Nov 28 17:37:41 2015 (r291430) @@ -542,8 +542,7 @@ static int i915_dispatch_batchbuffer(str return ret; if (INTEL_INFO(dev)->gen >= 4) { - OUT_RING(MI_BATCH_BUFFER_START | (2 << 6) | - MI_BATCH_NON_SECURE_I965); + OUT_RING(MI_BATCH_BUFFER_START | (2 << 6) | MI_BATCH_NON_SECURE_I965); OUT_RING(batch->start); } else { OUT_RING(MI_BATCH_BUFFER_START | (2 << 6)); @@ -724,7 +723,8 @@ int i915_cmdbuffer(struct drm_device *de cliprects = malloc(cmdbuf->num_cliprects * sizeof(struct drm_clip_rect), DRM_MEM_DMA, M_WAITOK | M_ZERO); ret = -copyin(cmdbuf->cliprects, cliprects, - cmdbuf->num_cliprects * sizeof(struct drm_clip_rect)); +cmdbuf->num_cliprects * +sizeof(struct drm_clip_rect)); if (ret != 0) goto fail_clip_free; } @@ -1325,7 +1325,7 @@ void i915_master_destroy(struct drm_devi */ int i915_driver_load(struct drm_device *dev, unsigned long flags) { - struct drm_i915_private *dev_priv = dev->dev_private; + struct drm_i915_private *dev_priv; const struct intel_device_info *info; unsigned long base, size; int ret = 0, mmio_bar; ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291428 - head/sys/dev/drm2/i915
Author: dumbbell Date: Sat Nov 28 15:22:46 2015 New Revision: 291428 URL: https://svnweb.freebsd.org/changeset/base/291428 Log: drm/i915: Reduce diff with Linux 3.8 There is no functional change. The goal is to ease the future update to Linux 3.8's i915 driver. MFC after:2 months Modified: head/sys/dev/drm2/i915/i915_debug.c Modified: head/sys/dev/drm2/i915/i915_debug.c == --- head/sys/dev/drm2/i915/i915_debug.c Sat Nov 28 14:30:42 2015 (r291427) +++ head/sys/dev/drm2/i915/i915_debug.c Sat Nov 28 15:22:46 2015 (r291428) @@ -294,14 +294,11 @@ static int i915_gem_gtt_info(struct drm_ static int i915_gem_pageflip_info(struct drm_device *dev, struct sbuf *m, void *data) { struct intel_crtc *crtc; - struct drm_i915_gem_object *obj; - struct intel_unpin_work *work; - char pipe; - char plane; list_for_each_entry(crtc, >mode_config.crtc_list, base.head) { - pipe = pipe_name(crtc->pipe); - plane = plane_name(crtc->plane); + const char pipe = pipe_name(crtc->pipe); + const char plane = plane_name(crtc->plane); + struct intel_unpin_work *work; mtx_lock(>event_lock); work = crtc->unpin_work; @@ -323,12 +320,12 @@ static int i915_gem_pageflip_info(struct sbuf_printf(m, "%d prepares\n", work->pending); if (work->old_fb_obj) { - obj = work->old_fb_obj; + struct drm_i915_gem_object *obj = work->old_fb_obj; if (obj) sbuf_printf(m, "Old framebuffer gtt_offset 0x%08x\n", obj->gtt_offset); } if (work->pending_flip_obj) { - obj = work->pending_flip_obj; + struct drm_i915_gem_object *obj = work->pending_flip_obj; if (obj) sbuf_printf(m, "New framebuffer gtt_offset 0x%08x\n", obj->gtt_offset); } @@ -390,7 +387,8 @@ static int i915_gem_request_info(struct return 0; } -static void i915_ring_seqno_info(struct sbuf *m, struct intel_ring_buffer *ring) +static void i915_ring_seqno_info(struct sbuf *m, +struct intel_ring_buffer *ring) { if (ring->get_seqno) { sbuf_printf(m, "Current sequence (%s): %d\n", @@ -496,9 +494,9 @@ static int i915_interrupt_info(struct dr atomic_read(_priv->irq_received)); for (i = 0; i < I915_NUM_RINGS; i++) { if (IS_GEN6(dev) || IS_GEN7(dev)) { - sbuf_printf(m, "Graphics Interrupt mask (%s): %08x\n", - dev_priv->rings[i].name, - I915_READ_IMR(_priv->rings[i])); + sbuf_printf(m, + "Graphics Interrupt mask (%s): %08x\n", + dev_priv->rings[i].name, I915_READ_IMR(_priv->rings[i])); } i915_ring_seqno_info(m, _priv->rings[i]); } @@ -678,8 +676,6 @@ static int i915_error_state(struct drm_d return 0; } - error = dev_priv->first_error; - sbuf_printf(m, "Time: %jd s %jd us\n", (intmax_t)error->time.tv_sec, (intmax_t)error->time.tv_usec); sbuf_printf(m, "PCI ID: 0x%04x\n", dev->pci_device); @@ -767,7 +763,7 @@ static int i915_error_state(struct drm_d } static int -i915_error_state_w(struct drm_device *dev, const char *str, void *unused) +i915_error_state_write(struct drm_device *dev, const char *str, void *unused) { drm_i915_private_t *dev_priv = dev->dev_private; struct drm_i915_error_state *error; @@ -782,8 +778,7 @@ i915_error_state_w(struct drm_device *de return (0); } -static int -i915_rstdby_delays(struct drm_device *dev, struct sbuf *m, void *unused) +static int i915_rstdby_delays(struct drm_device *dev, struct sbuf *m, void *unused) { drm_i915_private_t *dev_priv = dev->dev_private; u16 crstanddelay; @@ -795,8 +790,7 @@ i915_rstdby_delays(struct drm_device *de DRM_UNLOCK(dev); - sbuf_printf(m, "w/ctx: %d, w/o ctx: %d\n", - (crstanddelay >> 8) & 0x3f, (crstanddelay & 0x3f)); + sbuf_printf(m, "w/ctx: %d, w/o ctx: %d\n", (crstanddelay >> 8) & 0x3f, (crstanddelay & 0x3f)); return 0; } @@ -928,8 +922,7 @@ static int i915_inttoext_table(struct dr static int ironlake_drpc_info(struct drm_device *dev, struct sbuf *m) { drm_i915_private_t *dev_priv = dev->dev_private; - u32 rgvmodectl; - u32 rstdbyctl; + u32 rgvmodectl, rstdbyctl; u16 crstandvid;
svn commit: r291434 - head/sys/dev/sfxge/common
Author: arybchik Date: Sun Nov 29 05:38:40 2015 New Revision: 291434 URL: https://svnweb.freebsd.org/changeset/base/291434 Log: sfxge: cleanup: fix prefast annotations on mac stats updates Submitted by: Andy Moreton Sponsored by: Solarflare Communications, Inc. MFC after: 2 days X-MFC with: r291397 Modified: head/sys/dev/sfxge/common/siena_impl.h Modified: head/sys/dev/sfxge/common/siena_impl.h == --- head/sys/dev/sfxge/common/siena_impl.h Sun Nov 29 05:34:00 2015 (r291433) +++ head/sys/dev/sfxge/common/siena_impl.h Sun Nov 29 05:38:40 2015 (r291434) @@ -375,19 +375,19 @@ siena_phy_oui_get( #if EFSYS_OPT_PHY_STATS -extern void +extern void siena_phy_decode_stats( - __inefx_nic_t *enp, - __inuint32_t vmask, - __in_optefsys_mem_t *esmp, - __out_opt uint64_t *smaskp, - __out_ecount_opt(EFX_PHY_NSTATS)uint32_t *stat); + __inefx_nic_t *enp, + __inuint32_t vmask, + __in_optefsys_mem_t *esmp, + __out_opt uint64_t *smaskp, + __inout_ecount_opt(EFX_PHY_NSTATS) uint32_t *stat); extern __checkReturn int siena_phy_stats_update( __inefx_nic_t *enp, __inefsys_mem_t *esmp, - __out_ecount(EFX_PHY_NSTATS)uint32_t *stat); + __inout_ecount(EFX_PHY_NSTATS) uint32_t *stat); #endif /* EFSYS_OPT_PHY_STATS */ ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291438 - head/sys/mips/conf
Author: adrian Date: Sun Nov 29 05:49:49 2015 New Revision: 291438 URL: https://svnweb.freebsd.org/changeset/base/291438 Log: Add support for the integrated wifi for the QCA953x base config and AP143. Tested: * AP143 reference design board Modified: head/sys/mips/conf/AP143.hints head/sys/mips/conf/QCA953X_BASE head/sys/mips/conf/QCA953X_BASE.hints Modified: head/sys/mips/conf/AP143.hints == --- head/sys/mips/conf/AP143.hints Sun Nov 29 05:47:52 2015 (r291437) +++ head/sys/mips/conf/AP143.hints Sun Nov 29 05:49:49 2015 (r291438) @@ -24,6 +24,10 @@ hint.arge.1.phymask=0x0 # No directly m hint.arge.1.media=1000 hint.arge.1.fduplex=1 +# ath0: Where the ART is - last 64k in the flash +hint.ath.0.eepromaddr=0x1fff +hint.ath.0.eepromsize=16384 + # The AP121 4MB flash layout: # # bootargs=console=ttyS0,115200 root=31:02 rootfstype=squashfs Modified: head/sys/mips/conf/QCA953X_BASE == --- head/sys/mips/conf/QCA953X_BASE Sun Nov 29 05:47:52 2015 (r291437) +++ head/sys/mips/conf/QCA953X_BASE Sun Nov 29 05:49:49 2015 (r291438) @@ -100,7 +100,7 @@ option AH_DEBUG_ALQ device ath_ar9300 # AR9330 HAL; no need for the others option AH_DEBUG option AH_SUPPORT_AR5416 # 11n HAL support -option AH_SUPPORT_AR9330 # Chipset support +option AH_SUPPORT_QCA9530 # Chipset support option AH_AR5416_INTERRUPT_MITIGATION device mii Modified: head/sys/mips/conf/QCA953X_BASE.hints == --- head/sys/mips/conf/QCA953X_BASE.hints Sun Nov 29 05:47:52 2015 (r291437) +++ head/sys/mips/conf/QCA953X_BASE.hints Sun Nov 29 05:49:49 2015 (r291438) @@ -50,9 +50,7 @@ hint.ath.0.maddr=0x1810 hint.ath.0.msize=0x2 hint.ath.0.irq=0 hint.ath.0.vendor_id=0x168c -# XXX for now this is 0x00ff because there's no HAL support -# yet for honeybee. -hint.ath.0.device_id=0x00ff +hint.ath.0.device_id=0x003d # Set this to define where the ath calibration data # should be fetched from in physical memory. # hint.ath.0.eepromaddr=0x1fff1000 ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291432 - head/sys/dev/sfxge/common
Author: arybchik Date: Sun Nov 29 05:08:23 2015 New Revision: 291432 URL: https://svnweb.freebsd.org/changeset/base/291432 Log: sfxge: modify nvram update functions for uio platform to support RFID-selectable presets Dynamic config partitions on boards that support RFID are divided into a number of segments, each formatted like a partition, with header, trailer and end tags. The first segment is the current active configuration. The segments are initialised by manftest and each contain a different configuration e.g. firmware variant. The firmware can be instructed via RFID to copy a segment over the first segment, hence changing the active configuration. This allows ops to change the configuration of a board prior to shipment using RFID. Changes to the dynamic config may need to be written to all segments (in particular firmware versions written by manftest) or just the first segment (changes to the active configuration). See SF-111324-SW. If only the first segment is written the code still needs to be aware of the possible presence of subsequent segments as writing to a segment may cause its size to increase, which would overwrite the subsequent segments and invalidate them. Boards that do not support RFID will only have one segment in their dynamic config partition. Submitted by: Paul Fox Sponsored by: Solarflare Communications, Inc. MFC after: 2 days Differential Revision: https://reviews.freebsd.org/D4302 Modified: head/sys/dev/sfxge/common/hunt_impl.h head/sys/dev/sfxge/common/hunt_nvram.c head/sys/dev/sfxge/common/hunt_vpd.c Modified: head/sys/dev/sfxge/common/hunt_impl.h == --- head/sys/dev/sfxge/common/hunt_impl.h Sat Nov 28 17:38:27 2015 (r291431) +++ head/sys/dev/sfxge/common/hunt_impl.h Sun Nov 29 05:08:23 2015 (r291432) @@ -295,8 +295,8 @@ hunt_mcdi_macaddr_change_supported( extern __checkReturn int hunt_nvram_buf_read_tlv( __inefx_nic_t *enp, - __in_bcount(partn_size) caddr_t partn_data, - __insize_t partn_size, + __in_bcount(max_seg_size) caddr_t seg_data, + __insize_t max_seg_size, __inuint32_t tag, __deref_out_bcount_opt(*sizep) caddr_t *datap, __out size_t *sizep); @@ -327,6 +327,15 @@ hunt_nvram_partn_write_tlv( __insize_t size); extern __checkReturn int +hunt_nvram_partn_write_segment_tlv( + __inefx_nic_t *enp, + __inuint32_t partn, + __inuint32_t tag, + __in_bcount(size) caddr_t data, + __insize_t size, + __inboolean_t all_segments); + +extern __checkReturn int hunt_nvram_partn_size( __inefx_nic_t *enp, __inunsigned int partn, Modified: head/sys/dev/sfxge/common/hunt_nvram.c == --- head/sys/dev/sfxge/common/hunt_nvram.c Sat Nov 28 17:38:27 2015 (r291431) +++ head/sys/dev/sfxge/common/hunt_nvram.c Sun Nov 29 05:08:23 2015 (r291432) @@ -571,13 +571,19 @@ fail1: return (rc); } -/* Read and validate an entire TLV formatted partition */ -static __checkReturn int -hunt_nvram_read_tlv_partition( - __inefx_nic_t *enp, - __inuint32_t partn, - __in_bcount(partn_size) caddr_t partn_data, - __insize_t partn_size) +/* + * Read and validate a segment from a partition. A segment is a complete + * tlv chain between PARTITION_HEADER and PARTITION_END tags. There may + * be multiple segments in a partition, so seg_offset allows segments + * beyond the first to be read. + */ +static __checkReturn int +hunt_nvram_read_tlv_segment( + __inefx_nic_t *enp, + __inuint32_t partn, + __insize_t seg_offset, + __in_bcount(max_seg_size) caddr_t seg_data, + __insize_t max_seg_size) { tlv_cursor_t cursor; struct tlv_partition_header *header; @@ -589,20 +595,20 @@ hunt_nvram_read_tlv_partition( EFX_STATIC_ASSERT(sizeof (*header) <= HUNTINGTON_NVRAM_CHUNK); - if ((partn_data == NULL) || (partn_size == 0)) { + if ((seg_data == NULL) || (max_seg_size == 0)) { rc = EINVAL; goto fail1; } - /* Read initial chunk of partition */ - if ((rc = hunt_nvram_partn_read(enp, partn, 0, partn_data, + /* Read initial chunk of
svn commit: r291433 - head/sys/contrib/dev/ath/ath_hal/ar9300
Author: adrian Date: Sun Nov 29 05:34:00 2015 New Revision: 291433 URL: https://svnweb.freebsd.org/changeset/base/291433 Log: [ath_hal] add AR9461 (jupiter) 2.1 support. Obtained from:Linux ath9k Added: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9462_2p0_initvals.h (contents, props changed) head/sys/contrib/dev/ath/ath_hal/ar9300/ar9462_2p1_initvals.h (contents, props changed) Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300reg.h Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c == --- head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c Sun Nov 29 05:08:23 2015(r291432) +++ head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c Sun Nov 29 05:34:00 2015(r291433) @@ -39,6 +39,7 @@ #include "ar9300/ar9485_1_1.ini" #include "ar9300/ar9300_jupiter10.ini" #include "ar9300/ar9300_jupiter20.ini" +#include "ar9300/ar9462_2p1_initvals.h" #include "ar9300/ar9580.ini" #include "ar9300/ar955x.ini" #include "ar9300/ar9300_aphrodite10.ini" @@ -1598,11 +1599,21 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC else if (AR_SREV_JUPITER_20(ah)) { /* Jupiter: new INI format (pre, core, post arrays per subsystem) */ +/* FreeBSD: just override the registers for jupiter 2.1 */ + /* mac */ INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_PRE], NULL, 0, 0); -INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_CORE], -ar9300_jupiter_2p0_mac_core, -ARRAY_LENGTH(ar9300_jupiter_2p0_mac_core), 2); + +if (AR_SREV_JUPITER_21(ah)) { +INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_CORE], + ar9462_2p1_mac_core, + ARRAY_LENGTH(ar9462_2p1_mac_core), 2); +} else { +INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_CORE], +ar9300_jupiter_2p0_mac_core, +ARRAY_LENGTH(ar9300_jupiter_2p0_mac_core), 2); +} + INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_POST], ar9300_jupiter_2p0_mac_postamble, ARRAY_LENGTH(ar9300_jupiter_2p0_mac_postamble), 5); @@ -1612,9 +1623,16 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC INIT_INI_ARRAY(>ah_ini_bb[ATH_INI_CORE], ar9300_jupiter_2p0_baseband_core, ARRAY_LENGTH(ar9300_jupiter_2p0_baseband_core), 2); -INIT_INI_ARRAY(>ah_ini_bb[ATH_INI_POST], -ar9300_jupiter_2p0_baseband_postamble, -ARRAY_LENGTH(ar9300_jupiter_2p0_baseband_postamble), 5); + +if (AR_SREV_JUPITER_21(ah)) { +INIT_INI_ARRAY(>ah_ini_bb[ATH_INI_POST], +ar9462_2p1_baseband_postamble, +ARRAY_LENGTH(ar9462_2p1_baseband_postamble), 5); +} else { +INIT_INI_ARRAY(>ah_ini_bb[ATH_INI_POST], +ar9300_jupiter_2p0_baseband_postamble, +ARRAY_LENGTH(ar9300_jupiter_2p0_baseband_postamble), 5); +} /* radio */ INIT_INI_ARRAY(>ah_ini_radio[ATH_INI_PRE], NULL, 0, 0); @@ -1629,9 +1647,15 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC ARRAY_LENGTH(ar9300_jupiter_2p0_radio_postamble_sys2ant), 5); /* soc */ -INIT_INI_ARRAY(>ah_ini_soc[ATH_INI_PRE], -ar9300_jupiter_2p0_soc_preamble, -ARRAY_LENGTH(ar9300_jupiter_2p0_soc_preamble), 2); +if (AR_SREV_JUPITER_21(ah)) { +INIT_INI_ARRAY(>ah_ini_soc[ATH_INI_PRE], + ar9462_2p1_soc_preamble, + ARRAY_LENGTH(ar9462_2p1_soc_preamble), 2); +} else { +INIT_INI_ARRAY(>ah_ini_soc[ATH_INI_PRE], + ar9300_jupiter_2p0_soc_preamble, + ARRAY_LENGTH(ar9300_jupiter_2p0_soc_preamble), 2); +} INIT_INI_ARRAY(>ah_ini_soc[ATH_INI_CORE], NULL, 0, 0); INIT_INI_ARRAY(>ah_ini_soc[ATH_INI_POST], ar9300_jupiter_2p0_soc_postamble, Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300reg.h == --- head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300reg.h Sun Nov 29 05:08:23 2015(r291432) +++ head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300reg.h Sun Nov 29 05:34:00 2015(r291433) @@ -2970,6 +2970,7 @@ enum { #define AR_SREV_REVISION_JUPITER_10 0 /* Jupiter 1.0 */ #define AR_SREV_REVISION_JUPITER_20 2 /* Jupiter 2.0 */ +#define AR_SREV_REVISION_JUPITER_21 3 /* Jupiter 2.1 */ #define AR_SREV_REVISION_APHRODITE_10 0 /* Aphrodite 1.0 */ @@ -3012,10 +3013,18 @@ enum { ((AH_PRIVATE((_ah))->ah_macVersion == AR_SREV_VERSION_JUPITER) && \ (AH_PRIVATE((_ah))->ah_macRev == AR_SREV_REVISION_JUPITER_20)) +#define AR_SREV_JUPITER_21(_ah) \ +((AH_PRIVATE((_ah))->ah_macVersion == AR_SREV_VERSION_JUPITER) && \ + (AH_PRIVATE((_ah))->ah_macRev == AR_SREV_REVISION_JUPITER_21))
svn commit: r291435 - head/sys/contrib/dev/ath/ath_hal/ar9300
Author: adrian Date: Sun Nov 29 05:42:18 2015 New Revision: 291435 URL: https://svnweb.freebsd.org/changeset/base/291435 Log: u32 -> uint32_t. Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9462_2p1_initvals.h Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9462_2p1_initvals.h == --- head/sys/contrib/dev/ath/ath_hal/ar9300/ar9462_2p1_initvals.h Sun Nov 29 05:38:40 2015(r291434) +++ head/sys/contrib/dev/ath/ath_hal/ar9300/ar9462_2p1_initvals.h Sun Nov 29 05:42:18 2015(r291435) @@ -58,7 +58,7 @@ #define ar9462_2p1_pciephy_clkreq_disable_L1 ar9462_2p0_pciephy_clkreq_disable_L1 -static const u32 ar9462_2p1_mac_core[][2] = { +static const uint32_t ar9462_2p1_mac_core[][2] = { /* Addr allmodes */ {0x0008, 0x}, {0x0030, 0x000e0085}, @@ -221,7 +221,7 @@ static const u32 ar9462_2p1_mac_core[][2 {0x83d0, 0x000301ff}, }; -static const u32 ar9462_2p1_baseband_postamble[][5] = { +static const uint32_t ar9462_2p1_baseband_postamble[][5] = { /* Addr 5G_HT20 5G_HT40 2G_HT40 2G_HT20 */ {0x9810, 0xd00a8005, 0xd00a8005, 0xd00a8011, 0xd00a800d}, {0x9820, 0x206a022e, 0x206a022e, 0x206a012e, 0x206a01ae}, @@ -280,7 +280,7 @@ static const u32 ar9462_2p1_baseband_pos {0xb284, 0x, 0x, 0x0550, 0x0550}, }; -static const u32 ar9462_2p1_soc_preamble[][2] = { +static const uint32_t ar9462_2p1_soc_preamble[][2] = { /* Addr allmodes */ {0x40a4, 0x00a0c9c9}, {0x7020, 0x}, ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291436 - head/sys/dev/sfxge/common
Author: arybchik Date: Sun Nov 29 05:42:49 2015 New Revision: 291436 URL: https://svnweb.freebsd.org/changeset/base/291436 Log: sfxge: add prefast annotation to common code return types Using a typedef for common code return types (rather than "int") allows the Prefast static analyser to understand when a function has been successful (and thus when its postconditions must hold). This greatly reduces then number of false positives reported by prefast for error paths in common code functions. Submitted by: Andy Moreton Sponsored by: Solarflare Communications, Inc. MFC after: 2 days Modified: head/sys/dev/sfxge/common/efsys.h head/sys/dev/sfxge/common/efx.h head/sys/dev/sfxge/common/efx_bootcfg.c head/sys/dev/sfxge/common/efx_ev.c head/sys/dev/sfxge/common/efx_filter.c head/sys/dev/sfxge/common/efx_impl.h head/sys/dev/sfxge/common/efx_intr.c head/sys/dev/sfxge/common/efx_mac.c head/sys/dev/sfxge/common/efx_mcdi.c head/sys/dev/sfxge/common/efx_mcdi.h head/sys/dev/sfxge/common/efx_mon.c head/sys/dev/sfxge/common/efx_nic.c head/sys/dev/sfxge/common/efx_nvram.c head/sys/dev/sfxge/common/efx_phy.c head/sys/dev/sfxge/common/efx_port.c head/sys/dev/sfxge/common/efx_rx.c head/sys/dev/sfxge/common/efx_sram.c head/sys/dev/sfxge/common/efx_tx.c head/sys/dev/sfxge/common/efx_vpd.c head/sys/dev/sfxge/common/efx_wol.c head/sys/dev/sfxge/common/hunt_ev.c head/sys/dev/sfxge/common/hunt_filter.c head/sys/dev/sfxge/common/hunt_impl.h head/sys/dev/sfxge/common/hunt_intr.c head/sys/dev/sfxge/common/hunt_mac.c head/sys/dev/sfxge/common/hunt_mcdi.c head/sys/dev/sfxge/common/hunt_nic.c head/sys/dev/sfxge/common/hunt_nvram.c head/sys/dev/sfxge/common/hunt_phy.c head/sys/dev/sfxge/common/hunt_rx.c head/sys/dev/sfxge/common/hunt_sram.c head/sys/dev/sfxge/common/hunt_tx.c head/sys/dev/sfxge/common/hunt_vpd.c head/sys/dev/sfxge/common/mcdi_mon.c head/sys/dev/sfxge/common/mcdi_mon.h head/sys/dev/sfxge/common/siena_impl.h head/sys/dev/sfxge/common/siena_mac.c head/sys/dev/sfxge/common/siena_mcdi.c head/sys/dev/sfxge/common/siena_nic.c head/sys/dev/sfxge/common/siena_nvram.c head/sys/dev/sfxge/common/siena_phy.c head/sys/dev/sfxge/common/siena_sram.c head/sys/dev/sfxge/common/siena_vpd.c Modified: head/sys/dev/sfxge/common/efsys.h == --- head/sys/dev/sfxge/common/efsys.h Sun Nov 29 05:42:18 2015 (r291435) +++ head/sys/dev/sfxge/common/efsys.h Sun Nov 29 05:42:49 2015 (r291436) @@ -225,6 +225,7 @@ sfxge_map_mbuf_fast(bus_dma_tag_t tag, b #define__deref_out_bcount_opt(n) #define__checkReturn +#define__success(_x) #define__drv_when(_p, _c) Modified: head/sys/dev/sfxge/common/efx.h == --- head/sys/dev/sfxge/common/efx.h Sun Nov 29 05:42:18 2015 (r291435) +++ head/sys/dev/sfxge/common/efx.h Sun Nov 29 05:42:49 2015 (r291436) @@ -40,11 +40,21 @@ extern "C" { #endif -#defineEFX_STATIC_ASSERT(_cond) ((void)sizeof(char[(_cond) ? 1 : -1])) +#defineEFX_STATIC_ASSERT(_cond)\ + ((void)sizeof(char[(_cond) ? 1 : -1])) -#defineEFX_ARRAY_SIZE(_array) (sizeof(_array) / sizeof((_array)[0])) +#defineEFX_ARRAY_SIZE(_array) \ + (sizeof(_array) / sizeof((_array)[0])) -#defineEFX_FIELD_OFFSET(_type, _field) ((size_t) &(((_type *)0)->_field)) +#defineEFX_FIELD_OFFSET(_type, _field) \ + ((size_t) &(((_type *)0)->_field)) + +/* Return codes */ + +typedef __success(return == 0) int efx_rc_t; + + +/* Chip families */ typedef enum efx_family_e { EFX_FAMILY_INVALID, @@ -54,13 +64,13 @@ typedef enum efx_family_e { EFX_FAMILY_NTYPES } efx_family_t; -extern __checkReturn int +extern __checkReturn efx_rc_t efx_family( __inuint16_t venid, __inuint16_t devid, __out efx_family_t *efp); -extern __checkReturn int +extern __checkReturn efx_rc_t efx_infer_family( __inefsys_bar_t *esbp, __out efx_family_t *efp); @@ -124,7 +134,7 @@ typedef struct efx_nic_sefx_nic_t; #defineEFX_NIC_FUNC_TRUSTED0x0004 -extern __checkReturn int +extern __checkReturn efx_rc_t efx_nic_create( __inefx_family_t family, __inefsys_identifier_t *esip, @@ -132,34 +142,34 @@ efx_nic_create( __inefsys_lock_t *eslp, __deref_out efx_nic_t **enpp); -extern __checkReturn int +extern __checkReturn efx_rc_t efx_nic_probe( __inefx_nic_t *enp); #if EFSYS_OPT_PCIE_TUNE -extern __checkReturn int +extern __checkReturn efx_rc_t efx_nic_pcie_tune( __inefx_nic_t *enp,
svn commit: r291440 - head/tests/sys/mqueue
Author: deischen Date: Sun Nov 29 06:16:25 2015 New Revision: 291440 URL: https://svnweb.freebsd.org/changeset/base/291440 Log: Disable a couple of tests, perhaps temporarily, since they use private symbols that are not exported from librt. Modified: head/tests/sys/mqueue/Makefile Modified: head/tests/sys/mqueue/Makefile == --- head/tests/sys/mqueue/Makefile Sun Nov 29 06:14:51 2015 (r291439) +++ head/tests/sys/mqueue/Makefile Sun Nov 29 06:16:25 2015 (r291440) @@ -10,8 +10,8 @@ CFLAGS+= -I${SRCTOP}/tests PROGS+=mqtest1 PROGS+=mqtest2 -PROGS+=mqtest3 -PROGS+=mqtest4 +#PROGS+= mqtest3 +#PROGS+= mqtest4 PROGS+=mqtest5 LDADD+=-lrt ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291437 - head/sys/contrib/dev/ath/ath_hal/ar9300
Author: adrian Date: Sun Nov 29 05:47:52 2015 New Revision: 291437 URL: https://svnweb.freebsd.org/changeset/base/291437 Log: Add initial support for the QCA953x SoC (honeybee) wifi. This is a 2x2 2GHz 802.11n part. It works enough at the moment to bring up, scan and associate. I haven't started using this as a day to day AP. The specifics: * add honeybee initvals * add in changes; a mix from the QCA HAL and ath9k; * fix a bug in AR_SREV_AR9580_10_OR_LATER(), which is only used for one capability check and we don't even implement it - so it's a big no-op. Shady things: * ath9k has the "platform data" define the 25/40MHz clock. This HAL .. doesn't. Honeybee gets hard-coded to 25MHz which it likely shouldn't be. I'll have to go and identify/fix those. Tested: * Qualcomm Atheros AP143 reference design board. Obtained from:Qualcomm Atheros; Linux ath9k Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_eeprom.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_freebsd_inc.h head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_radar.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_radio.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_recv.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_reset.c head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300reg.h Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c == --- head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c Sun Nov 29 05:42:49 2015(r291436) +++ head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c Sun Nov 29 05:47:52 2015(r291437) @@ -42,6 +42,7 @@ #include "ar9300/ar9462_2p1_initvals.h" #include "ar9300/ar9580.ini" #include "ar9300/ar955x.ini" +#include "ar9300/ar953x.ini" #include "ar9300/ar9300_aphrodite10.ini" @@ -566,6 +567,9 @@ ar9300_read_revisions(struct ath_hal *ah } else if(AH_PRIVATE(ah)->ah_devid == AR9300_DEVID_QCA955X) { /* XXX: AR_SREV register in Scorpion reads 0 */ AH_PRIVATE(ah)->ah_macVersion = AR_SREV_VERSION_SCORPION; +} else if(AH_PRIVATE(ah)->ah_devid == AR9300_DEVID_QCA953X) { +/* XXX: AR_SREV register in HoneyBEE reads 0 */ + AH_PRIVATE(ah)->ah_macVersion = AR_SREV_VERSION_HONEYBEE; } else { /* * Include 6-bit Chip Type (masked to 0) @@ -799,6 +803,11 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC #undef AR9340_SOC_SEL_25M_40M #undef AR9340_REF_CLK_40 } + +if (AR_SREV_HONEYBEE(ah)) { +ahp->clk_25mhz = 1; +} + ar9300_init_pll(ah, AH_NULL); if (!ar9300_set_power_mode(ah, HAL_PM_AWAKE, AH_TRUE)) { @@ -823,6 +832,7 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC ahpriv->ah_macVersion != AR_SREV_VERSION_HORNET && ahpriv->ah_macVersion != AR_SREV_VERSION_POSEIDON && ahpriv->ah_macVersion != AR_SREV_VERSION_SCORPION && +ahpriv->ah_macVersion != AR_SREV_VERSION_HONEYBEE && ahpriv->ah_macVersion != AR_SREV_VERSION_JUPITER && ahpriv->ah_macVersion != AR_SREV_VERSION_APHRODITE) ) { HALDEBUG(ah, HAL_DEBUG_RESET, @@ -1376,6 +1386,15 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC ar9340Modes_fast_clock_wasp_1p0, ARRAY_LENGTH(ar9340Modes_fast_clock_wasp_1p0), 3); +/* XXX TODO: need to add this for freebsd; it's missing from the current .ini files */ +#if 0 +/* Japan 2484Mhz CCK settings */ +INIT_INI_ARRAY(>ah_ini_japan2484, +ar9340_wasp_1p0_baseband_core_txfir_coeff_japan_2484, +ARRAY_LENGTH( +ar9340_wasp_1p0_baseband_core_txfir_coeff_japan_2484), 2); +#endif + /* Additional setttings for 40Mhz */ INIT_INI_ARRAY(>ah_ini_modes_additional_40mhz, ar9340_wasp_1p0_radio_core_40M, @@ -1445,6 +1464,67 @@ ar9300_attach(u_int16_t devid, HAL_SOFTC //INIT_INI_ARRAY(>ah_ini_modes_additional_40M, //ar955x_scorpion_1p0_radio_core_40M, //ARRAY_LENGTH(ar955x_scorpion_1p0_radio_core_40M), 2); +} else if (AR_SREV_HONEYBEE(ah)) { +/* mac */ +INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_PRE], NULL, 0, 0); +INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_CORE], +qca953x_honeybee_1p0_mac_core, +ARRAY_LENGTH(qca953x_honeybee_1p0_mac_core), 2); +INIT_INI_ARRAY(>ah_ini_mac[ATH_INI_POST], +qca953x_honeybee_1p0_mac_postamble, +ARRAY_LENGTH(qca953x_honeybee_1p0_mac_postamble), 5); + +/* bb */ +INIT_INI_ARRAY(>ah_ini_bb[ATH_INI_PRE], NULL, 0, 0); +INIT_INI_ARRAY(>ah_ini_bb[ATH_INI_CORE], +qca953x_honeybee_1p0_baseband_core, +ARRAY_LENGTH(qca953x_honeybee_1p0_baseband_core), 2); +
svn commit: r291439 - head/lib/librt
Author: deischen Date: Sun Nov 29 06:14:51 2015 New Revision: 291439 URL: https://svnweb.freebsd.org/changeset/base/291439 Log: Unbreak symbol versioning. I have no idea when it was broken, but it's been at least a few months if not a year or more. Added: head/lib/librt/Symbol.map (contents, props changed) Deleted: head/lib/librt/Version.map Modified: head/lib/librt/Makefile Modified: head/lib/librt/Makefile == --- head/lib/librt/Makefile Sun Nov 29 05:49:49 2015(r291438) +++ head/lib/librt/Makefile Sun Nov 29 06:14:51 2015(r291439) @@ -17,7 +17,8 @@ SRCS+= aio.c mq.c sigev_thread.c timer.c PRECIOUSLIB= -VERSION_MAP= ${.CURDIR}/Version.map +VERSION_DEF=${.CURDIR}/../libc/Versions.def +SYMBOL_MAPS=${.CURDIR}/Symbol.map .if ${MK_TESTS} != "no" SUBDIR+= tests Added: head/lib/librt/Symbol.map == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/librt/Symbol.map Sun Nov 29 06:14:51 2015(r291439) @@ -0,0 +1,69 @@ +/* + * $FreeBSD$ + */ + +FBSD_1.0 { + aio_read; + aio_write; + aio_return; + aio_waitcomplete; + aio_fsync; + mq_open; + mq_close; + mq_notify; + mq_getattr; + mq_setattr; + mq_timedreceive; + mq_timedsend; + mq_unlink; + mq_send; + mq_receive; + timer_create; + timer_delete; + timer_gettime; + timer_settime; + timer_getoverrun; +}; + +FBSDprivate_1.0 { + _aio_read; + _aio_write; + _aio_return; + _aio_waitcomplete; + _aio_fsync; + __aio_read; + __aio_write; + __aio_return; + __aio_waitcomplete; + __aio_fsync; + _mq_open; + _mq_close; + _mq_notify; + _mq_getattr; + _mq_setattr; + _mq_timedreceive; + _mq_timedsend; + _mq_unlink; + _mq_send; + _mq_receive; + __mq_open; + __mq_close; + __mq_notify; + __mq_getattr; + __mq_setattr; + __mq_timedreceive; + __mq_timedsend; + __mq_unlink; + __mq_send; + __mq_receive; + _timer_create; + _timer_delete; + _timer_gettime; + _timer_settime; + _timer_getoverrun; + __timer_create; + __timer_delete; + __timer_gettime; + __timer_settime; + __timer_getoverrun; +}; ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291441 - head/sys/conf
Author: nwhitehorn Date: Sun Nov 29 06:40:09 2015 New Revision: 291441 URL: https://svnweb.freebsd.org/changeset/base/291441 Log: Fix build with new binutils. This gets a working kernel with GCC 5.2 and binutils 2.24. Without this, the self-relocation code in locore64.S was failing due to a misaligned TOC section. MFC after:2 weeks Modified: head/sys/conf/ldscript.powerpc64 Modified: head/sys/conf/ldscript.powerpc64 == --- head/sys/conf/ldscript.powerpc64Sun Nov 29 06:16:25 2015 (r291440) +++ head/sys/conf/ldscript.powerpc64Sun Nov 29 06:40:09 2015 (r291441) @@ -69,6 +69,7 @@ SECTIONS .toc1 : ALIGN(8) { *(.toc1) } .opd : ALIGN(8) { KEEP (*(.opd)) } .branch_lt : ALIGN(8) { *(.branch_lt) } + . = ALIGN(4096); .got : ALIGN(8) { __tocbase = .; *(.got .toc) } .dynamic: { *(.dynamic) } ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r291442 - in head/sys/powerpc: aim include powerpc
Author: nwhitehorn Date: Sun Nov 29 07:16:08 2015 New Revision: 291442 URL: https://svnweb.freebsd.org/changeset/base/291442 Log: Make ELFv2 powerpc64 kernels build and run. Loader support will come in a separate commit. Modified: head/sys/powerpc/aim/locore64.S head/sys/powerpc/include/asm.h head/sys/powerpc/powerpc/exec_machdep.c head/sys/powerpc/powerpc/swtch64.S head/sys/powerpc/powerpc/vm_machdep.c Modified: head/sys/powerpc/aim/locore64.S == --- head/sys/powerpc/aim/locore64.S Sun Nov 29 06:40:09 2015 (r291441) +++ head/sys/powerpc/aim/locore64.S Sun Nov 29 07:16:08 2015 (r291442) @@ -65,6 +65,10 @@ #include #include +#ifdef _CALL_ELF +.abiversion _CALL_ELF +#endif + /* Locate the per-CPU data structure */ #define GET_CPUINFO(r) \ mfsprg0 r Modified: head/sys/powerpc/include/asm.h == --- head/sys/powerpc/include/asm.h Sun Nov 29 06:40:09 2015 (r291441) +++ head/sys/powerpc/include/asm.h Sun Nov 29 07:16:08 2015 (r291442) @@ -87,7 +87,9 @@ .tc name[TC],name #endif -#if defined(__powerpc64__) && (!defined(_CALL_ELF) || _CALL_ELF == 1) +#ifdef __powerpc64__ + +#if !defined(_CALL_ELF) || _CALL_ELF == 1 #define_ENTRY(name) \ .section ".text"; \ .p2align 2; \ @@ -100,6 +102,17 @@ .p2align 4; \ TYPE_ENTRY(name) \ DOT_LABEL(name): +#else +#define_ENTRY(name) \ + .text; \ + .p2align 4; \ + .globl name; \ + .type name,@function; \ +name: \ + addis %r2, %r12, (.TOC.-name)@ha; \ + addi%r2, %r2, (.TOC.-name)@l; \ + .localentry name, .-name; +#endif #define_END(name) \ .long 0; \ Modified: head/sys/powerpc/powerpc/exec_machdep.c == --- head/sys/powerpc/powerpc/exec_machdep.c Sun Nov 29 06:40:09 2015 (r291441) +++ head/sys/powerpc/powerpc/exec_machdep.c Sun Nov 29 07:16:08 2015 (r291442) @@ -972,11 +972,12 @@ cpu_set_upcall(struct thread *td, struct cf->cf_arg1 = (register_t)tf; pcb2->pcb_sp = (register_t)cf; - #ifdef __powerpc64__ + #if defined(__powerpc64__) && (!defined(_CALL_ELF) || _CALL_ELF == 1) pcb2->pcb_lr = ((register_t *)fork_trampoline)[0]; pcb2->pcb_toc = ((register_t *)fork_trampoline)[1]; #else pcb2->pcb_lr = (register_t)fork_trampoline; + pcb2->pcb_context[0] = pcb2->pcb_lr; #endif pcb2->pcb_cpu.aim.usr_vsid = 0; Modified: head/sys/powerpc/powerpc/swtch64.S == --- head/sys/powerpc/powerpc/swtch64.S Sun Nov 29 06:40:09 2015 (r291441) +++ head/sys/powerpc/powerpc/swtch64.S Sun Nov 29 07:16:08 2015 (r291442) @@ -65,6 +65,10 @@ #include #include +#ifdef _CALL_ELF +.abiversion _CALL_ELF +#endif + TOC_ENTRY(blocked_lock) /* Modified: head/sys/powerpc/powerpc/vm_machdep.c == --- head/sys/powerpc/powerpc/vm_machdep.c Sun Nov 29 06:40:09 2015 (r291441) +++ head/sys/powerpc/powerpc/vm_machdep.c Sun Nov 29 07:16:08 2015 (r291442) @@ -143,7 +143,7 @@ cpu_fork(struct thread *td1, struct proc cf = (struct callframe *)tf - 1; memset(cf, 0, sizeof(struct callframe)); - #ifdef __powerpc64__ + #if defined(__powerpc64__) && (!defined(_CALL_ELF) || _CALL_ELF == 1) cf->cf_toc = ((register_t *)fork_return)[1]; #endif cf->cf_func = (register_t)fork_return; @@ -152,11 +152,12 @@ cpu_fork(struct thread *td1, struct proc pcb->pcb_sp = (register_t)cf; KASSERT(pcb->pcb_sp % 16 == 0, ("stack misaligned")); - #ifdef __powerpc64__ + #if defined(__powerpc64__) && (!defined(_CALL_ELF) || _CALL_ELF == 1) pcb->pcb_lr = ((register_t *)fork_trampoline)[0]; pcb->pcb_toc = ((register_t *)fork_trampoline)[1]; #else pcb->pcb_lr = (register_t)fork_trampoline; + pcb->pcb_context[0] = pcb->pcb_lr; #endif #ifdef AIM pcb->pcb_cpu.aim.usr_vsid = 0; ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"