Home | History | Annotate | Download | only in dev
History log of /src/sys/arch/algor/dev/mainbus.c
RevisionDateAuthorComments
 1.31  20-Dec-2023  thorpej Remove unnecessary <sys/malloc.h>.
 1.30  07-Aug-2021  thorpej Merge thorpej-cfargs2.
 1.29  24-Apr-2021  thorpej branches: 1.29.8;
Merge thorpej-cfargs branch:

Simplify and make extensible the config_search() / config_found() /
config_attach() interfaces: rather than having different variants for
which arguments you want pass along, just have a single call that
takes a variadic list of tag-value arguments.

Adjust all call sites:
- Simplify wherever possible; don't pass along arguments that aren't
actually needed.
- Don't be explicit about what interface attribute is attaching if
the device only has one. (More simplification.)
- Add a config_probe() function to be used in indirect configuiration
situations, making is visibly easier to see when indirect config is
in play, and allowing for future change in semantics. (As of now,
this is just a wrapper around config_match(), but that is an
implementation detail.)

Remove unnecessary or redundant interface attributes where they're not
needed.

There are currently 5 "cfargs" defined:
- CFARG_SUBMATCH (submatch function for direct config)
- CFARG_SEARCH (search function for indirect config)
- CFARG_IATTR (interface attribte)
- CFARG_LOCATORS (locators array)
- CFARG_DEVHANDLE (devhandle_t - wraps OFW, ACPI, etc. handles)

...and a sentinel value CFARG_EOL.

Add some extra sanity checking to ensure that interface attributes
aren't ambiguous.

Use CFARG_DEVHANDLE in MI FDT, OFW, and ACPI code, and macppc and shark
ports to associate those device handles with device_t instance. This
will trickle trough to more places over time (need back-end for pre-OFW
Sun OBP; any others?).
 1.28  07-Jul-2020  thorpej branches: 1.28.4;
Overhaul the interface to pci_configure_bus():
- Don't expose how PCI bus configuration resource management is implemented.
Provide a new resource provider API:

==> pciconf_resource_init() -- Initialize a PCI configuration resources
container.
==> pciconf_resource_add() -- Add a PCI configuration resource to the
container (I/O, MEM, or prefetchable MEM). Multiple resources of
each type may be added.
==> pciconf_resource_fini() -- Tear down the PCI configurtation resources
container once the bus has been configured.

This is much easier to use than the previous method of providing an
extent map for each kind of resource, and works better for e.g. ACPI
platforms that provide potentially multiple PCI resources in tables
provided by firmware.

- Re-implement PCI configuration resource management using vmem arenas,
rather than extent maps.
 1.27  14-Jun-2020  chs replace EX_NOWAIT with EX_WAITOK in device attach methods.
remove checks for failures that can no longer occur.
 1.26  27-Jan-2012  para converting extent(9) from malloc(9) to kmem(9)
preceding kmem-vmem-pool-uvm patch

releng@ acknowledged
 1.25  09-Jul-2011  matt branches: 1.25.2; 1.25.6;
Allow algor kernels to be built under either algor/algor64 or
evbmips-el/evbmips64-el. Note that MAXMAPARITITONS and majors numbers
differ between the two ports which is why two kernels are still needed.
 1.24  08-Jul-2011  matt Major update of algor.
Now uses generic mips bus_space.h bus_dma.h isa_machdep.h pci_machdep.h
Now uses evbmips versions of cpu.c isadma_bounce.c mcclock_isa.c
 1.23  01-Jul-2011  dyoung #include <sys/bus.h> instead of <machine/bus.h>.
 1.22  05-Jun-2011  matt struct device * -> device_t, struct cfdata * -> cfdata_t
CFATTACH_DECL(*, sizeof(struct device), -> CFATTACH_DECL_NEW(&, 0
 1.21  20-Feb-2011  matt branches: 1.21.2;
Merge forward from matt-nb5-mips64.
Adapt to new interrupt/spl framework.
 1.20  28-Apr-2008  martin branches: 1.20.18; 1.20.22; 1.20.28; 1.20.30;
Remove clause 3 and 4 from TNF licenses
 1.19  11-Dec-2005  christos branches: 1.19.74; 1.19.76; 1.19.78;
merge ktrace-lwp.
 1.18  26-Aug-2005  drochner s/locdesc_t/int/g
 1.17  30-Jun-2005  drochner branches: 1.17.2;
adaptions to config_search() change, and minor autoconf fixes, mostly from Havard Eidnes
 1.16  28-Jun-2005  drochner kill questionable uses of config(8) generated xxxlocnames[]
locator information does belong elsewhere and definitely shouldn't
be in the global namespace
 1.15  28-Jun-2005  drochner convert remaining autoconf bus "submatch" functions to use the new
signature (passing locators), and remove some which obviously don't
serve any purpose
(untested, sorry)
 1.14  14-Jul-2003  lukem add __KERNEL_RCSID()
 1.13  01-Jan-2003  thorpej branches: 1.13.2;
Use aprint_normal() for cfprint() routines.
 1.12  02-Oct-2002  thorpej Fix script-o's in last.
 1.11  02-Oct-2002  thorpej Use CFATTACH_DECL().
 1.10  27-Sep-2002  thorpej Declare all cfattach structures const.
 1.9  27-Sep-2002  thorpej Introduce a new routine, config_match(), which invokes the
cfattach->ca_match function in behalf of the caller. Use it
rather than invoking cfattach->ca_match directly.
 1.8  02-Jan-2002  thorpej Fix a typo.
 1.7  28-Nov-2001  thorpej Add a "cacheline_size" argument to pci_configure_bus(). It is used
to set the cacheline size in the BHLC register. This should be the
size of the largest D-cache line on a system.
 1.6  09-Nov-2001  thorpej branches: 1.6.2;
Add a "firstbus" argument to pci_configure_bus(), indicating the
first bus number to use, rather than always assuming that we should
start at bus #0.
 1.5  20-Oct-2001  simonb branches: 1.5.2;
Fix a tyop in a comment.
 1.4  22-Aug-2001  thorpej If PCI_NETBSD_ENABLE_IDE is set, enable the PIIX{3,4} southbridge
IDE channels on the P-5064 and P-6032, since PMON doesn't do it
for us (thus causing the `pciide' driver to ignore them).
 1.3  22-Jun-2001  thorpej branches: 1.3.2;
Check in work-in-progress of P-6032 support. This is not tested,
but is meant for back-up purposes.
 1.2  01-Jun-2001  thorpej Add support for the Algorithmics P-4032 board. This is totally
untested, since I have no P-4032 board, but it's no worse than
the current situation, which is "totally non-working P-4032
support in the ARC port, of all places".
 1.1  28-May-2001  thorpej A port to the Algorithmics MIPS evaluation boards. We currently
support the P-5064, which has a QED RM5xxx CPU soldered on.

There is some skeletal support for the P-4032 (an older board, which
had an R4xxx CPU). There are some placeholders for the P-6032, which
is their newest board, but no real code yet (the P-6032 has a different
PCI controller, the Algorithmics BONITO).

There are still some (apprently softintr-related) problems with the
algor kernel, but it works well-enough to self-host.

Kudos to Allegro Networks for loaning me a P-5064 board on which to do
the port.
 1.3.2.3  10-Oct-2002  jdolecek sync kqueue with -current; this includes merge of gehenna-devsw branch,
merge of i386 MP branch, and part of autoconf rototil work
 1.3.2.2  10-Jan-2002  thorpej Sync kqueue branch with -current.
 1.3.2.1  25-Aug-2001  thorpej Merge Aug 24 -current into the kqueue branch.
 1.5.2.1  12-Nov-2001  thorpej Sync the thorpej-mips-cache branch with -current.
 1.6.2.6  03-Jan-2003  thorpej Sync with HEAD.
 1.6.2.5  18-Oct-2002  nathanw Catch up to -current.
 1.6.2.4  28-Feb-2002  nathanw Catch up to -current.
 1.6.2.3  11-Jan-2002  nathanw More catchup.
 1.6.2.2  08-Jan-2002  nathanw Catch up to -current.
 1.6.2.1  09-Nov-2001  nathanw file mainbus.c was added on branch nathanw_sa on 2002-01-08 00:22:50 +0000
 1.13.2.4  10-Nov-2005  skrll Sync with HEAD. Here we go again...
 1.13.2.3  21-Sep-2004  skrll Fix the sync with head I botched.
 1.13.2.2  18-Sep-2004  skrll Sync with HEAD.
 1.13.2.1  03-Aug-2004  skrll Sync with HEAD
 1.17.2.1  21-Jun-2006  yamt sync with head.
 1.19.78.1  16-May-2008  yamt sync with head.
 1.19.76.1  18-May-2008  yamt sync with head.
 1.19.74.1  02-Jun-2008  mjf Sync with HEAD.
 1.20.30.1  05-Mar-2011  bouyer Sync with HEAD
 1.20.28.1  06-Jun-2011  jruoho Sync with HEAD.
 1.20.22.2  12-Jun-2011  rmind sync with head
 1.20.22.1  05-Mar-2011  rmind sync with head
 1.20.18.1  20-Jan-2010  matt Adjust things to the new world order.
 1.21.2.1  23-Jun-2011  cherry Catchup with rmind-uvmplock merge.
 1.25.6.1  18-Feb-2012  mrg merge to -current.
 1.25.2.1  17-Apr-2012  yamt sync with head
 1.28.4.2  22-Mar-2021  thorpej Audit CFARG_IATTR in config_found() calls, and remove it in situations
where the interface attribute is not ambiguous.
 1.28.4.1  22-Mar-2021  thorpej Mechanical conversion of config_found_sm_loc() -> config_found().
CFARG_IATTR usage needs to be audited.
 1.29.8.1  03-Aug-2021  thorpej Adapt to CFARGS().

RSS XML Feed