Home | History | Annotate | Download | only in sbus
History log of /src/sys/dev/sbus/spif.c
RevisionDateAuthorComments
 1.35  26-Oct-2022  riastradh spif(4): Convert to ttylock/ttyunlock.
 1.34  07-Aug-2021  thorpej Merge thorpej-cfargs2.
 1.33  24-Apr-2021  thorpej branches: 1.33.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.32  10-Nov-2019  chs branches: 1.32.10;
in many device attach paths, allocate memory with M_WAITOK instead of M_NOWAIT
and remove code to handle failures that can no longer happen.
 1.31  25-Jul-2014  dholland branches: 1.31.28;
Add d_discard to all struct cdevsw instances I could find.

All have been set to "nodiscard"; some should get a real implementation.
 1.30  16-Mar-2014  dholland branches: 1.30.2;
Change (mostly mechanically) every cdevsw/bdevsw I can find to use
designated initializers.

I have not built every extant kernel so I have probably broken at
least one build; however I've also found and fixed some wrong
cdevsw/bdevsw entries so even if so I think we come out ahead.
 1.29  15-Sep-2013  martin Remove unused variables
 1.28  18-Jul-2011  mrg branches: 1.28.2; 1.28.12; 1.28.16;
convert the remaining dev/sbus drivers to CFATTACH_DECL_NEW, cfdata_t
and device_t, including the pci frontend and backend for en(4).
 1.27  02-Jul-2011  mrg avoid some uninitialised variable warnings from GCC 4.5. i'm pretty
sure they can't happen in practise, but i can see why GCC isn't sure.
 1.26  24-Apr-2011  rmind Rename ttymalloc() to tty_alloc(), and ttyfree() to tty_free() for
consistency. Remove some unnecessary malloc.h inclusions as well.
 1.25  19-Sep-2009  tsutsui branches: 1.25.4; 1.25.6;
u_intNN_t -> uintNN_t
 1.24  17-Sep-2009  tsutsui Include "ioconf.h" instead of extern struct cfdriver foo_cd decls.
 1.23  12-May-2009  cegger struct device * -> device_t, no functional changes intended.
 1.22  12-May-2009  cegger struct cfdata * -> cfdata_t, no functional changes intended.
 1.21  14-Mar-2009  dsl ANSIfy another 1261 function definitions.
The only ones left in sys are beyond by sed script!
(or in sys/dist or sys/external)
Mostly they have function pointer parameters.
 1.20  14-Mar-2009  dsl Change about 4500 of the K&R function definitions to ANSI ones.
There are still about 1600 left, but they have ',' or /* ... */
in the actual variable definitions - which my awk script doesn't handle.
There are also many that need () -> (void).
(The script does handle misordered arguments.)
 1.19  11-Dec-2008  hauke branches: 1.19.2;
Fix warning about missing initializer that showed up in sparc64
builds, but, strangely enough, not in sparc builds.

Relevant for netbsd-{4,5} release branches.
 1.18  11-Jun-2008  drochner branches: 1.18.2; 1.18.4; 1.18.6;
mechanical changes to use device_private() or device_lookup_private()
to get softcs, makes the code compile under the stricter type checking
introduced earlier today
 1.17  11-Jun-2008  cegger - use device_lookup_private to get softc
- ansify
fixes build errors about pointer type mismatches in assignment
 1.16  25-May-2008  ad branches: 1.16.2;
Properly fix the "hanging in tty" bug that was worked around with cv_wakeup()
some time again.
 1.15  05-Apr-2008  cegger branches: 1.15.2; 1.15.4; 1.15.6;
use aprint_*_dev and device_xname
 1.14  19-Nov-2007  ad branches: 1.14.14;
- Factor out too many copies of the same bit of tty code.
- Fix another tty signalling/wakeup problem.
 1.13  07-Nov-2007  ad Merge tty changes from the vmlocking branch.
 1.12  19-Oct-2007  ad branches: 1.12.2;
machine/{bus,cpu,intr}.h -> sys/{bus,cpu,intr}.h
 1.11  08-Oct-2007  ad branches: 1.11.2;
Use the softint API.
 1.10  04-Mar-2007  christos branches: 1.10.2; 1.10.14; 1.10.16; 1.10.18;
Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.
 1.9  01-Oct-2006  elad branches: 1.9.2; 1.9.4;
More from Matt Fleming:

Adapt to KAUTH_DEVICE_TTY_PRIVSET and KAUTH_DEVICE_TTY_OPEN.
 1.8  01-Oct-2006  elad Adapt MD code to KAUTH_DEVICE_TTY_OPEN, batch #2 from Matt Fleming, thanks!

Also, add forgotten splx() calls in some places.
 1.7  21-Jul-2006  ad branches: 1.7.4; 1.7.6;
- Use the LWP cached credentials where sane.
- Minor cosmetic changes.
 1.6  15-May-2006  yamt include kauth.h for kauth_authorize_generic.
 1.5  14-May-2006  elad integrate kauth.
 1.4  11-Dec-2005  christos branches: 1.4.4; 1.4.6; 1.4.8; 1.4.10; 1.4.12;
merge ktrace-lwp.
 1.3  06-Sep-2005  kleink Change the driver open function's conditional for overriding exclusive tty
use from checking the proc's uid to suser(9), and account for the use of
privileges. Noted by David Holland in PR kern/31126.
 1.2  27-Feb-2005  perry branches: 1.2.4;
nuke trailing whitespace
 1.1  24-Jul-2004  mrg branches: 1.1.2; 1.1.6; 1.1.8;
Hauke Fath's port of the openbsd SUNW,spif driver from PR#26061.
the driver was originally written by Jason L. Wright.

XXX: i haven't tested this on sparc64 at all...
 1.1.8.1  19-Mar-2005  yamt sync with head. xen and whitespace. xen part is not finished.
 1.1.6.1  29-Apr-2005  kent sync with -current
 1.1.2.7  10-Nov-2005  skrll Sync with HEAD. Here we go again...
 1.1.2.6  04-Mar-2005  skrll Sync with HEAD.

Hi Perry!
 1.1.2.5  04-Feb-2005  skrll Adapt to branch.
 1.1.2.4  21-Sep-2004  skrll Fix the sync with head I botched.
 1.1.2.3  18-Sep-2004  skrll Sync with HEAD.
 1.1.2.2  03-Aug-2004  skrll Sync with HEAD
 1.1.2.1  24-Jul-2004  skrll file spif.c was added on branch ktrace-lwp on 2004-08-03 10:51:05 +0000
 1.2.4.6  07-Dec-2007  yamt sync with head
 1.2.4.5  15-Nov-2007  yamt sync with head.
 1.2.4.4  27-Oct-2007  yamt sync with head.
 1.2.4.3  03-Sep-2007  yamt sync with head.
 1.2.4.2  30-Dec-2006  yamt sync with head.
 1.2.4.1  21-Jun-2006  yamt sync with head.
 1.4.12.1  24-May-2006  tron Merge 2006-05-24 NetBSD-current into the "peter-altq" branch.
 1.4.10.2  10-Mar-2006  elad generic_authorize() -> kauth_authorize_generic().
 1.4.10.1  08-Mar-2006  elad Adapt to kernel authorization KPI.
 1.4.8.2  11-Aug-2006  yamt sync with head
 1.4.8.1  24-May-2006  yamt sync with head.
 1.4.6.1  01-Jun-2006  kardel Sync with head.
 1.4.4.1  09-Sep-2006  rpaulo sync with head
 1.7.6.1  22-Oct-2006  yamt sync with head
 1.7.4.1  18-Nov-2006  ad Sync with head.
 1.9.4.1  12-Mar-2007  rmind Sync with HEAD.
 1.9.2.1  10-Dec-2010  bouyer Pull up following revision(s) (requested by hauke in ticket #1412):
sys/dev/sbus/spif.c: revision 1.19
Fix warning about missing initializer that showed up in sparc64
builds, but, strangely enough, not in sparc builds.
Relevant for netbsd-{4,5} release branches.
 1.10.18.1  14-Oct-2007  yamt sync with head.
 1.10.16.3  09-Jan-2008  matt sync with HEAD
 1.10.16.2  08-Nov-2007  matt sync with -HEAD
 1.10.16.1  06-Nov-2007  matt sync with HEAD
 1.10.14.3  21-Nov-2007  joerg Sync with HEAD.
 1.10.14.2  11-Nov-2007  joerg Sync with HEAD.
 1.10.14.1  26-Oct-2007  joerg Sync with HEAD.

Follow the merge of pmap.c on i386 and amd64 and move
pmap_init_tmp_pgtbl into arch/x86/x86/pmap.c. Modify the ACPI wakeup
code to restore CR4 before jumping back into kernel space as the large
page option might cover that.
 1.10.2.2  23-Oct-2007  ad Sync with head.
 1.10.2.1  17-Jun-2007  ad - Increase the number of thread priorities from 128 to 256. How the space
is set up is to be revisited.
- Implement soft interrupts as kernel threads. A generic implementation
is provided, with hooks for fast-path MD code that can run the interrupt
threads over the top of other threads executing in the kernel.
- Split vnode::v_flag into three fields, depending on how the flag is
locked (by the interlock, by the vnode lock, by the file system).
- Miscellaneous locking fixes and improvements.
 1.11.2.3  21-Nov-2007  bouyer Sync with HEAD
 1.11.2.2  13-Nov-2007  bouyer Sync with HEAD
 1.11.2.1  25-Oct-2007  bouyer Sync with HEAD.
 1.12.2.2  08-Dec-2007  mjf Sync with HEAD.
 1.12.2.1  19-Nov-2007  mjf Sync with HEAD.
 1.14.14.3  17-Jan-2009  mjf Sync with HEAD.
 1.14.14.2  29-Jun-2008  mjf Sync with HEAD.
 1.14.14.1  02-Jun-2008  mjf Sync with HEAD.
 1.15.6.1  23-Jun-2008  wrstuden Sync w/ -current. 34 merge conflicts to follow.
 1.15.4.3  11-Mar-2010  yamt sync with head
 1.15.4.2  16-May-2009  yamt sync with head
 1.15.4.1  04-May-2009  yamt sync with head.
 1.15.2.2  17-Jun-2008  yamt sync with head.
 1.15.2.1  04-Jun-2008  yamt sync with head
 1.16.2.1  18-Jun-2008  simonb Sync with head.
 1.18.6.1  07-Jan-2011  riz Pull up following revision(s) (requested by hauke in ticket #1506):
sys/dev/sbus/spif.c: revision 1.19
Fix warning about missing initializer that showed up in sparc64
builds, but, strangely enough, not in sparc builds.
Relevant for netbsd-{4,5} release branches.
 1.18.4.2  28-Apr-2009  skrll Sync with HEAD.
 1.18.4.1  19-Jan-2009  skrll Sync with HEAD.
 1.18.2.1  13-Dec-2008  haad Update haad-dm branch to haad-dm-base2.
 1.19.2.1  13-May-2009  jym Sync with HEAD.

Commit is split, to avoid a "too many arguments" protocol error.
 1.25.6.1  06-Jun-2011  jruoho Sync with HEAD.
 1.25.4.1  31-May-2011  rmind sync with head
 1.28.16.1  18-May-2014  rmind sync with head
 1.28.12.1  20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.28.2.1  22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.30.2.1  10-Aug-2014  tls Rebase.
 1.31.28.1  13-Apr-2020  martin Mostly merge changes from HEAD upto 20200411
 1.32.10.1  21-Mar-2021  thorpej Give config_found() the same variadic arguments treatment as
config_search(). This commit only adds the CFARG_EOL sentinel
to the existing config_found() calls. Conversion of config_found_sm_loc()
and config_found_ia() call sites will be in subsequent commits.
 1.33.8.1  04-Aug-2021  thorpej Adapt to CFARGS().

RSS XML Feed