summaryrefslogtreecommitdiff
path: root/sys/dev/ic/z8530tty.c
AgeCommit message (Collapse)Author
2022-10-26zs(4): Convert to ttylock/ttyunlock.riastradh
2019-11-10in many device attach paths, allocate memory with M_WAITOK instead of M_NOWAITchs
and remove code to handle failures that can no longer happen.
2019-07-21Fix panic due to inconsistent lock states of tty_lock in zsparam().rin
Tested on mac68k.
2017-10-31As discussed on tech-kern: define a new tty internal state flag: TS_KERN_ONLYmartin
Implement it in a few tty drivers. If this flag is set, the underlying hardware is used by another driver and userland has no right to open it. A few uses will appear soon in sys/dev/sun/sun{kbd,ms}.c.
2014-11-15centralize the dialout/call unit macros.christos
2014-07-25Add d_discard to all struct cdevsw instances I could find.dholland
All have been set to "nodiscard"; some should get a real implementation.
2014-03-16Change (mostly mechanically) every cdevsw/bdevsw I can find to usedholland
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.
2011-04-24Rename ttymalloc() to tty_alloc(), and ttyfree() to tty_free() forrmind
consistency. Remove some unnecessary malloc.h inclusions as well.
2009-05-22add two new functions for z8530tty: zs_chan_lock() and zs_chan_unlock(),mrg
and use them instead of various spl's in the zs.c's. reviewed by ad and martin.
2009-05-12struct device * -> device_t, no functional changes intended.cegger
2009-05-12struct cfdata * -> cfdata_t, no functional changes intended.cegger
2009-03-20Try to avoid zstty hangs on higher speed:tsutsui
z8530sc.c: Check pending interrupts in a loop until all requests are handled. The old comments said it would cause horrible latency to sun3x floppy etc, but serial ports should have higher priority than disks anyway. z8530tty.c: Don't enable and disable TX interrupts on each transmit start and completion because it could cause possible race conditions. Instead, set ZSWR0_RESET_TXINT on each TIE interrupt to clear the request as other kbd drivers attached at zs(4). Tested on cobalt, macppc, news68k, sparc, and sun3.
2008-04-21Make ntp, pmc, reboot, sysarch, time syscalls MPSAFE.ad
2008-03-29Split softc and device_t for zsc(4) and its children.tsutsui
XXX we should restructure MI APIs and make it really machine independent.
2008-03-14Remove a tty_lock for now - I know that this is wrong, but the wholemartin
tty subsystem locking is not consistent and Andrew didn't have time to come up (or guide to) the right fix. This prevents machines with serial console on zs(4) from deadlocking on first input.
2008-01-20Now that __HAVE_TIMECOUNTER and __HAVE_GENERIC_TODR are invariants,joerg
remove the conditionals and the code associated with the undef case.
2007-12-22t_linesw->l_modem would ideally be called with tty_lock held, but beforead
that can happen someone needs to beat all the drivers into shape.
2007-12-22Don't recursively acquire tty_lock when zstty_softint() is called directly.ad
2007-11-19- Factor out too many copies of the same bit of tty code.ad
- Fix another tty signalling/wakeup problem.
2007-11-10zsstart, zstty_txsoft: don't acquire tty_lock, it's already held.ad
2007-11-07Merge tty changes from the vmlocking branch.ad
2007-07-09Merge some of the less invasive changes from the vmlocking branch:ad
- kthread, callout, devsw API changes - select()/poll() improvements - miscellaneous MT safety improvements
2007-03-04Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.christos
2006-10-01More from Matt Fleming:elad
Adapt to KAUTH_DEVICE_TTY_PRIVSET and KAUTH_DEVICE_TTY_OPEN.
2006-10-01Adapt MD code to KAUTH_DEVICE_TTY_OPEN, batch #2 from Matt Fleming, thanks!elad
Also, add forgotten splx() calls in some places.
2006-07-22Remove unused variable to make it compile again.martin
2006-07-21- Use the LWP cached credentials where sane.ad
- Minor cosmetic changes.
2006-06-07merge FreeBSD timecounters from branch simonb-timecounterskardel
- struct timeval time is gone time.tv_sec -> time_second - struct timeval mono_time is gone mono_time.tv_sec -> time_uptime - access to time via {get,}{micro,nano,bin}time() get* versions are fast but less precise - support NTP nanokernel implementation (NTP API 4) - further reading: Timecounter Paper: http://phk.freebsd.dk/pubs/timecounter.pdf NTP Nanokernel: http://www.eecis.udel.edu/~mills/ntp/html/kern.html
2006-05-14integrate kauth.elad
2006-04-19- use M_NOWAIT rather than M_WAITOK for malloc(9) to allocate RX buffertsutsui
in zstty_attach() - check a return value of the malloc(9) Taken from com.c, and somehow this seems to fix PR port-sun2/32420 on tme.
2006-03-29Use device_cfdata().thorpej
2006-03-28Use device_unit().thorpej
2006-03-05Remove SET/CLR/ISSET macros.rjs
2005-12-27switch macppc to use the MI zstty driver.chs
add macppc's ZS_TXDMA hooks there.
2005-12-11merge ktrace-lwp.christos
2005-09-06Change the driver open function's conditional for overriding exclusive ttykleink
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.
2005-06-30Allow sparc64-style attachment of mouse and keyboard via zstty, needed formacallan
wscons support. Reviewed by uwe.
2005-05-31- add constchristos
- avoid variable shadow
2005-02-27nuke trailing whitespaceperry
2005-02-04de-__Pperry
2004-06-20Define and use zsccf_channel as an alias for cf_loc[ZSCCF_CHANNEL].thorpej
2004-01-23Fix NTP PPSAPI support (enabled with "options PPS_SYNC"):simonb
From PR kern/13702 from Charles Carvalho. Tested on alpha and i386 with a Laipac TF10 PPS-capable GPS. The com.c change was copied wholesale from Charles' z8530tty.c patch.
2003-12-04netbsd.org -> NetBSD.orgkeihan
This was the last commit of this kind to src/sys, which is now totally "NetBSD.org clean". Thanks for the patiance, and sorry for all the commits.
2003-08-07Move UCB-licensed code from 4-clause to 3-clause licence.agc
Patches provided by Joel Baker in PR 22364, verified by myself.
2003-06-29Back out the lwp/ktrace changes. They contained a lot of colateral damage,fvdl
and need to be examined and discussed more.
2003-06-29More changes for providing lwpid for ktrace (sparc GENERIC built)darrenr
2003-01-28Provide locking required by the interrupt handlers running at IPL_SERIAL.pk
2003-01-24zs_shutdown: lower IPL before sleeping. Also note the fact that thepk
effectiveness of that very tsleep() call is dubious at best.
2003-01-06interrupt with two rs.wiz
2002-11-09Fix signed/unsigned comparison warnings.thorpej