This branch was a major cleanup and rototill of many of the various OEA
cpu based PPC ports that focused on sharing as much code as possible
between the various ports to eliminate near-identical copies of files in
every tree. Additionally there is a new PIC system that unifies the
interface to interrupt code for all different OEA ppc arches. The work
for this branch was done by a variety of people, too long to list here.
TODO:
bebox still needs work to complete the transition to -renovation.
ofppc still needs a bunch of work, which I will be looking at.
ev64260 still needs to be renovated
amigappc was not attempted.
NOTES:
pmppc was removed as an arch, and moved to a evbppc target.
need to understand the locking around that field. Instead of setting
B_ERROR, set b_error instead. b_error is 'owned' by whoever completes
the I/O request.
config_handle_wedges() and read_disk_sectors(). On x86, handle_wedges()
is a thin wrapper for config_handle_wedges(). Share opendisk()
across architectures.
Add kernel code in support of specifying a root partition by wedge
name. E.g., root specifications "wedge:wd0a", "wedge:David's Root
Volume" are possible. (Patches for config(1) coming soon.)
In support of moving disks between architectures (esp. i386 <->
evbmips), I've written a routine convertdisklabel() that ensures
that the raw partition is at RAW_DISK by following these steps:
0 If we have read a disklabel that has a RAW_PART with
p_offset == 0 and p_size != 0, then use that raw partition.
1 If we have read a disklabel that has both partitions 'c'
and 'd', and RAW_PART has p_offset != 0 or p_size == 0,
but the other partition is suitable for a raw partition
(p_offset == 0, p_size != 0), then swap the two partitions
and use the new raw partition.
2 If the architecture's raw partition is 'd', and if there
is no partition 'd', but there is a partition 'c' that
is suitable for a raw partition, then copy partition 'c'
to partition 'd'.
3 Determine the drive's last sector, using either the
d_secperunit the drive reported, or by guessing (0x1fffffff).
If we cannot read the drive's last sector, then fail.
4 If we have read a disklabel that has no partition slot
RAW_PART, then create a partition RAW_PART. Make it span
the whole drive.
5 If there are fewer than MAXPARTITIONS partitions,
then "slide" the unsuitable raw partition RAW_PART, and
subsequent partitions, into partition slots RAW_PART+1
and subsequent slots. Create a raw partition at RAW_PART.
Make it span the whole drive.
The convertdisklabel() procedure can probably stand to be simplified,
but it ought to deal with all but an extraordinarily broken disklabel,
now.
i386: compiled and tested, sparc64: compiled, evbmips: compiled.
FINDCOMM contains the find(1) command that produces the list of
NetBSD sources that all architectures share, COMM. For backwards
compatibility, evaluate FINDCOMM to produce ${COMM}.
In arch/evbmips/Makefile, use FINDCOMM directly, because the
command-line 'echo $COMM ...' was too long.
readdisklabel(9), which are better than the evbmips disk subroutines
at finding a BSD disklabel at a different location than the evbmips
default of sector 0, offset 64. Helps me boot a RouterBOARD 153
from a CompactFlash containing both a Master Boot Record at sector
0, and a BSD disklabel at sector 1, offset 0.
from doc/BRANCHES:
idle lwp, and some changes depending on it.
1. separate context switching and thread scheduling.
(cf. gmcgarry_ctxsw)
2. implement idle lwp.
3. clean up related MD/MI interfaces.
4. make scheduler(s) modular.
Basics: the ADM5120 is a 175 MHz MIPS32 4Kc processor featuring a
6-port ethernet 10/100 switch with Auto MDI/X, a PCI controller,
USB 1.1 controller, UART, watchdog timer, eight GPIO pins, and a
multiport memory controller with both NOR and NAND flash support.
This code supports most of the devices on the ADM5120, including
the 6-port switch (each port attaches as an ethernet, admsw0 through
admsw5), the PCI controller, USB controller, GPIO, watchdog, and
UART.
Remaining work: the port includes no NOR/NAND flash drivers. No
bootloader is included. I have only tested the PCI bus driver with
the use of one PCI slot on the RouterBOARD 153. It is not possible
to exploit the capabilities of the ethernet switch using bridge(4).
I have only netbooted the ADM5120 on the RB153. Booting other
boards, and booting from flash memory, remains to be done.
Hardware availability: many low-cost routers, including the
RouterBOARD 100 series at RouterBOARD.com, use the Infineon ADM5120
processor.
Credits: Ruslan Ermilov and Vsevolod Lobko ported to the ADM5120,
and they wrote device drivers for the UART, USB controller, and
10/100 switch. Matt Isaacs brought the port up-to-date with
NetBSD-current, made it compile, and ran it first on the RB153.
I added drivers for the PCI controller, GPIO, and watchdog timer.
I produced the bus attachment for the CompactFlash slot with advice
from Mikrotik technical support and from Matt Thomas.
locators for uhub because a hub can't have sub-devices.
This might be sanity-checked eventually.
Same for ubt now after the change to device attachment.
by Slava Semushin <slava.semushin@gmail.com>.
To verify that no nasty side effects of duplicate includes (or their
removal) have an effect here, I've compiled an i386/ALL kernel with
and without the patch, and the only difference in the resulting .o
files was in shifted line numbers in some assert() calls.
The comparison of the .o files was based on the output of "objdump -D".
Thanks to martin@ for the input on testing.
- finish implementing splraiseipl (and makeiplcookie).
http://mail-index.NetBSD.org/tech-kern/2006/07/01/0000.html
- complete workqueue(9) and fix its ipl problem, which is reported
to cause audio skipping.
- fix netbt (at least compilation problems) for some ports.
- fix PR/33218.
version.
Add disk_blocksize(9) so that disk drivers can record the physical
block size of a disk if it is different to DEV_BSIZE. Right now this
simply initialises dk_blkshift and dk_byteshift according to the
supplied block size. This information is used in the MI version of
bounds_check_with_label().
Pointed out by Havard Eidnes.
XXX: should these decls be in <mips/intr.h> or <mips/locore.h>?
While here, remove "extern" keyword from function declarations.
from cpu_configure(9) to cpu_initclocks(9) on mips ports which use
mips3_clockintr.c:mips3_clockintr() (i.e. CPU INT5 clock) to avoid
hardclock(9) before softclock interrupt is initialized in initclocks().
This should be harmless because initclocks() is a part of configure()
in these days and there is no MI function which expects hardware
interrupts between cpu_configure(9) and cpu_initclocks(9).
Disccussed on tech-kern and port-mips.
DBAU1550. This is parameterized somewhat as machdep pluggable code, so
different boards can supply different implementations.
At the moment, the DBAU1550 is the only Au1550 board I know of with SPI
connected devices.
I have not enabled I2C on the DBAU1550, as we do not have drivers for either
of the I2C connected devices (a different temperature/voltage sensor and
a serial eeprom.)
- Add COMPAT_15 to all the kernel that had COMPAT_14, for the sake of coherency
- Remove the only occurences of #ifdef COMPAT_15 in the tree: for the ARM
ports, COMPAT_15 was always used in conjunction with EXEC_AOUT. Only EXEC_AOUT
matters here.
This address kern/18407
the Meraki web site at http://www.meraki.net/ ) This includes changes
to the AR5312 to make it more conducive to sharing code with the AR5315,
and also includes improved early console support.
All devices including ethernet and wlan interfaces on the Meraki Mini are
functional with this port, _except_ SPI flash, which will be introduced
later.
This port was funded by the Champaign-Urbana Communit Wireless Network
Project (CUWiN).
useful. The functions delay, cpu_initclocks, and setstatclcokrate have been
renamed to mips3_delay, mips3_initclocks, and mips3_setstatclockrate.
We provide weak aliases for the original names, so machdep code doesn't have
to provide wrapper routines. (Giving good performance.)
I've moved mips3_clockintr, mips3_initclocks, and mips3_setstatclockrate to
their own mips3_clockintr file, because some ports may not be able to use
these, and its senseless to carry that baggage.
stuff necessary to separate out AR5312 from AR5315. This includes:
1) rework of arbus IRQs, so that IRQs are now seperately specified
as either MISC or CPU irqs
2) move board/chip-specific addresses into chip-dependent file
3) unencumber argpio from ar5312 specifics, using properties to pass
details such as reset-pin and sysled-pin.
4) an option to select which WiSoC is to be configured is provided.
AR5315 support should be forthcoming shortly now.
sharing of code with the AR5315, which has many similarities, but many
differences from the AR5312.
No functional change at this time, other than the cpu_model string
(and also sysctl.hw.model node) is changed to reflect the WiSoC cpu
name rather than the identification string in ROM (which tends to not
be very informative.)
instead of ../evbmips/, which was pretty fragile. Cope with long
argument lists using the echo ${args} | xargs ctags idiom used in
other architectures' tags target.
This allows us to convert aucom to just another com attachment, and cleanup
some code in the com_arbus.c.
Additionally, we use a common com_cleanup routine rather than having a
zillion copies of it in the attachment points.
This has been tested on a number architectures, and it has been shown to get
close to comparable performance when COM_REGMAP is defined, and comparable
when it is not defined.
Approved by core@. Fixes PR port-evbmips/32362.
the only convenient way to use the returned value with numerous library
routines which have not been altered to properly use constified char *.
This was found to be necessary when I extended yamon to hold a string
describing a video mode for use with my experimental radeonfb.
so that when it is pressed the default reset button action (currently board
reset, no change to data in flash) is taken.
While here, remove the AR531X generic config, because it just doesn't make
sense.
New HAL includes some driver changes to register accesses.
Adds support for WLAN devices on AR5312 family devices.
Adds support 32-bit SPARC ath devices (untested).
ath enabled in SPARC64 GENERIC builds.
This HAL is tested and known to work for i386 PCI devices, SPARC64 PCI devices,
and AR5312 WiSoC devices. MIPS PCI devices appear to be busted (possibly only
on Alchemy hardware, unconfirmed), and cardbus support is untested due to
lack of test hardware.
Please report any new problems with this import to garrett@.
Additionally, do not fail if no RTC is present, as not all boards have one.
Malta now uses the common dev/ic/mc146818.c code as much as possible, reducing
local "custom" code. These malta changes are *untested*, as I do not have
a Malta board to test with. If someone would please test them and get back to
me, I'd appreciate it!
Some devices work (an, wdc), while others do not (ne, wi).
However, the bus is useful enough that it makes sense to go ahead and
enable it. Maybe other folks can help me debug the rest of the problems.
and serial ports are supported, and the system appears stable with an NFS
mounted root. An earlier version of the code was reviewed by simon@, but it
has since had numerous improvements and cleanups.
At the moment, only AR5312 is known to work, but I suspect AR2313 will work
as well. Later 2315/2316 parts are substantially different, and are not yet
supported. Wifi and Marvell switch support found on some designs are not yet
supported.
Platforms known to include AR5312 include Senao Aries 2 (AP5054) and Netgear
WGU624.
I'm not enabling it in the configuration file yet. (I have an uncommitted
version of the config file that I will happily share with anyone who wants to
help test or debug.)
in the config are left intact, though.
Add a PMAP-driven bus_space for access to upper memory, instead of using
wired entries.
Convert aupci to use said bus_space -- no measured performance impact.
PCI idsel and irq routing (later).
Various cleanup/rototilling to remove hardcoded pb1000 references.
Reviewed by simonb@, and derived from changes reviewed by matt@ and tsutsui@
an overflow occurs.
. Make this error a fatal build time error
. Move the support for dbsym into the MI Makefile.kern.inc,
conditional upon the SYMTAB_SPACE option being defined in
the kernel config file.