summaryrefslogtreecommitdiffstats
path: root/sys/powerpc
Commit message (Collapse)AuthorAgeFilesLines
* - Remove the eintrcnt/eintrnames usage and introduce the concept ofattilio2011-07-183-6/+15
| | | | | | | | | | | | | | | | sintrcnt/sintrnames which are symbols containing the size of the 2 tables. - For amd64/i386 remove the storage of intr* stuff from assembly files. This area can be widely improved by applying the same to other architectures and likely finding an unified approach among them and move the whole code to be MI. More work in this area is expected to happen fairly soon. No MFC is previewed for this patch. Tested by: pluknet Reviewed by: jhb Approved by: re (kib)
* Enable PREEMPTION for PowerPC/AIM generic kernels. The last known PREEMPTIONnwhitehorn2011-07-142-0/+2
| | | | | bug on PowerPC was resolved by r223485, and it appears to run stably at this point.
* Follow Linux by unconditionally stripping the RX vlan tag from incomingnwhitehorn2011-07-051-4/+7
| | | | | | | packets. It turns out that all firmware versions insert it, whether or not they support VLAN tagging. Submitted by: glevand <geoffrey.levand at mail dot ru>
* With retirement of cpumask_t and usage of cpuset_t for representing aattilio2011-07-044-30/+19
| | | | | | | | | | | | | | | mask of CPUs, pc_other_cpus and pc_cpumask become highly inefficient. Remove them and replace their usage with custom pc_cpuid magic (as, atm, pc_cpumask can be easilly represented by (1 << pc_cpuid) and pc_other_cpus by (all_cpus & ~(1 << pc_cpuid))). This change is not targeted for MFC because of struct pcpu members removal and dependency by cpumask_t retirement. MD review by: marcel, marius, alc Tested by: pluknet MD testing by: marcel, marius, gonzo, andreast
* Add better error handling for RTAS calls. These can potentially causenwhitehorn2011-06-261-1/+18
| | | | | | | machine checks (e.g. invalid PCI configuration cycles), but these can be caught and recovered from. This change also the RTAS PCI driver to work without modification as a replacement for the Grackle driver on Grackle-based Powermacs.
* Revert r223479. It is unnecessary and served only to slightly amelioratenwhitehorn2011-06-262-4/+0
| | | | some manifestations of the bug actually fixed in r223485.
* Turn the minimum PWM fan speed down to 30 from 40. It turns out the burningnwhitehorn2011-06-261-1/+1
| | | | | | | smell that caused me to turn this up was due to a failed fan burning, not a CPU (plus a healthy dose of paranoia). Submitted by: Paul Mather <paul at gromit dot dlib dot vt dot edu>
* Use the ABI-mandated thread pointer register (r2 for ppc32, r13 for ppc64)nwhitehorn2011-06-2316-71/+82
| | | | | | | | | | | | | | | instead of a PCPU field for curthread. This averts a race on SMP systems with a high interrupt rate where the thread looking up the value of curthread could be preempted and migrated between obtaining the PCPU pointer and reading the value of pc_curthread, resulting in curthread being observed to be the current thread on the thread's original CPU. This played merry havoc with the system, in particular with mutexes. Many thanks to jhb for helping me work this one out. Note that Book-E is in principle susceptible to the same problem, but has not been modified yet due to lack of Book-E hardware. MFC after: 2 weeks
* Clear any outstanding atomic reservations when traps are taken. This fixesnwhitehorn2011-06-232-0/+4
| | | | | | some interesting bugs (mostly on SMP systems) with atomic operations silently failing in interrupt heavy situations, especially when using overflow pages.
* Fix merge typo.andreast2011-06-231-1/+1
|
* Add leading zeros when printing the stackframe on __powerpc64__.andreast2011-06-231-1/+1
|
* Use atomic operations to mask and unmask IRQs. This prevents a problemnwhitehorn2011-06-231-8/+8
| | | | | | (obvious in retrospect) in which interrupts on one CPU that are temporarily masked can end up permanently masked when a handler on another CPU clobbers the interrupt mask register with an old copy.
* Use 4 KB pages for storage bus devices, which seems to be what the HV usesnwhitehorn2011-06-231-2/+6
| | | | internally.
* Rework the PS3 disk driver to support NCQ and do its DMA a littlenwhitehorn2011-06-231-388/+189
| | | | differently.
* Add hypervisor call error codes.nwhitehorn2011-06-232-0/+56
|
* This is more complicated than I expected. Storage devices need the IOMMUnwhitehorn2011-06-221-2/+11
| | | | set up, but must not use it.
* The IOMMU is not involved for the storage bus.nwhitehorn2011-06-221-2/+1
|
* Work/hack around some race conditions present in the hardware/HV interface.nwhitehorn2011-06-201-14/+33
| | | | Partially inspired by a patch from glevand (geoffrey.levand@mail.ru).
* Make this slightly less yelly about regions that the hypervisor protectsnwhitehorn2011-06-201-2/+10
| | | | from us by not registering them as disks.
* Add an OHCI driver to complement the EHCI one. The infrastructure to attachnwhitehorn2011-06-201-0/+170
| | | | | both to the parent ps3bus was in r223313. This driver itself comes from the ps3 project branch.
* Driver for PS3's internal hard disk. Hopefully this can be CAM-ified innwhitehorn2011-06-203-22/+1068
| | | | | | | | the future, but presents a set of simple block devices for now. With (forthcoming) boot loader support or vfs.root.mountfrom, allows booting PS3s from disk. Submitted by: glevand <geoffrey.levand@mail.ru>
* Follow up r222980 on PowerPC: add sound(4) and common device driversnwhitehorn2011-06-112-8/+15
| | | | to PowerPC GENERIC (along with a small rearrangement).
* MFCattilio2011-06-048-61/+431
|\
| * Add new fan controller driver for the G4 MDD PowerMac. Submitted and testedandreast2011-06-043-0/+218
| | | | | | | | | | | | by Justin Hibbits. Approved by: nwhitehorn (mentor)
| * - Improve error handling.andreast2011-06-041-30/+60
| | | | | | | | | | | | - Add retry loops for the i2c read/write functions. Approved by: nwhitehorn (mentor)
| * Retry the memory map-related portions of r222613, written by andreast,nwhitehorn2011-06-041-26/+145
| | | | | | | | | | after some minor tweaks and an increase in the early-boot stack space in r222632.
| * Fix a typo derived from a mismerge from mmu_oea that would causenwhitehorn2011-06-041-2/+2
| | | | | | | | | | | | | | | | | | pmap_sync_icache() to sync random (possibly uncached or nonexisting!) memory, causing kernel page faults or machine checks, most easily triggered by using GDB. While here, add an additional safeguard to only sync cacheable memory. MFC after: 2 days
| * - Introduce a define for ZERO_C_TO_K.andreast2011-06-032-3/+6
| | | | | | | | | | | | - Fix the printing of the temperature when we exceed the critical value. Approved by: nwhitehorn (mentor)
* | MFCattilio2011-06-0318-260/+824
|\ \ | |/
| * Quantities stored on the stack on ppc64 tend to be twice as large as onnwhitehorn2011-06-031-1/+1
| | | | | | | | ppc32, so make the early stack correspondingly twice as big.
| * Temporarily back out those parts of r222613 related to parsing the memorynwhitehorn2011-06-021-144/+25
| | | | | | | | | | map. They cause non-understood boot failures on some Apple machines with more than 2 GB of RAM (like my work desktop).
| * The POWER7 has only 32 SLB slots instead of 64, like other supportednwhitehorn2011-06-024-44/+52
| | | | | | | | | | | | 64-bit PowerPC CPUs. Add infrastructure to support variable numbers of SLB slots and move the user slot from 63 to 0, so that it is always available.
| * If running under a hypervisor, don't yell at the user about startingnwhitehorn2011-06-021-1/+4
| | | | | | | | | | unknown CPU types, instead relying on the hypervisor to have given us a reasonable environment.
| * Explicitly initialize the first thread's MSR to PSL_KERNSET.nwhitehorn2011-06-021-1/+1
| |
| * Include the modules area in the mapped kernel code. This fixes the kernel'snwhitehorn2011-06-021-3/+2
| | | | | | | | | | access to modules and loader metadata when started from real mode, but without a direct map.
| * Remove some dead code: unnecessary isyncs and memory sorting, which arenwhitehorn2011-06-024-47/+9
| | | | | | | | handled in mtmsr() and mem_regions(), respectively.
| * MFpseries:nwhitehorn2011-06-029-187/+898
| | | | | | | | | | | | | | | | | | | | Renovate and improve the AIM Open Firmware support: - Add RTAS (Run-Time Abstraction Services) support, found on all IBM systems and some Apple ones - Improve support for 32-bit real mode Open Firmware systems - Pull some more OF bits over from the AIM directory - Fix memory detection on IBM LPARs and systems with more than one /memory node (by andreast@)
| * On multi-core, multi-threaded PPC systems, it is important that the threadsnwhitehorn2011-05-312-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | be brought up in the order they are enumerated in the device tree (in particular, that thread 0 on each core be brought up first). The SLIST through which we loop to start the CPUs has all of its entries added with SLIST_INSERT_HEAD(), which means it is in reverse order of enumeration and so AP startup would always fail in such situations (causing a machine check or RTAS failure). Fix this by changing the SLIST into an STAILQ, and inserting new CPUs at the end. Reviewed by: jhb
* | MFCattilio2011-05-312-5/+5
| |
* | MFCattilio2011-05-314-55/+88
|\ \ | |/
| * Use kproc_exit() instead of returning from the management function onnwhitehorn2011-05-291-1/+1
| | | | | | | | systems with no manageable thermal control devices.
| * Add some error handling here: if a sensor returns an error code (a negativenwhitehorn2011-05-291-1/+5
| | | | | | | | | | | | | | Kelvin temperature, which is impossible except for some contrived magnetic spin systems), use the previous measurement from that sensor instead of corrupting everything and randomly changing the fans or shutting off the machine.
| * Add the next digit of precision to temperatures, which I missed whennwhitehorn2011-05-292-2/+2
| | | | | | | | converting the reporting format from degrees C to 0.1 degree K.
| * Don't put negative values into the averages.nwhitehorn2011-05-291-0/+2
| |
| * Update the I2C-based temperature/fan drivers to connect to the Powermacnwhitehorn2011-05-291-51/+78
| | | | | | | | | | thermal control module. This provides automatic fan management on all G5 PowerMacs and Xserves.
| * Add a new driver, the ad7417, to read temperatures and voltages on someandreast2011-05-293-0/+3
| | | | | | | | | | | | PowerMac's. Approved by: nwhitehorn (mentor)
| * The P4080 has 8 cores. Bump MAXCPU to 8 to match.marcel2011-05-291-1/+1
| |
| * o Add system versions for the P4040(E) and P4080(E).marcel2011-05-292-5/+18
| | | | | | | | | | | | | | | | | | o In bare_probe(), change the logic that determines the maximum number of processors/cores into a switch statement and take advantage of the fact that bit 3 of the SVR value indicates whether we're running on a security enabled version. Since we don't care about that here, mask the bit. All -E versions are taken care of automatically.
* | MFCattilio2011-05-293-0/+3
| |
* | MFCattilio2011-05-2912-261/+447
|\ \ | |/
OpenPOWER on IntegriCloud