Commit Graph

72 Commits

Author SHA1 Message Date
nate
741ef8dac5 - Update the email address in the copyrights. 1997-11-04 18:12:51 +00:00
nate
b865ee4190 - If the APM BIOS fails to suspend the system after running the
suspend hooks, run the resume hooks to re-configure the system back
  to where it was.
1997-11-04 17:37:52 +00:00
nate
5ec2824fc0 - Back out the last. APM_BROKEN_STATCLOCK doesn't exist in -current. 1997-10-23 04:18:49 +00:00
nate
bdf762c6f9 - If APM_BROKEN_STATCLOCK is defined, make sure the statcloock is
disabled, don't rely on the flags to set it.
1997-10-22 23:04:07 +00:00
gibbs
0e62d096db Convert to the new callout interface. 1997-09-21 21:33:10 +00:00
wollman
016c0a5f21 Fix crash when halting where APM was configured but not enabled
by checking whether APM is active in apm_power_off() and returning
if not.  (The code was already written with the expectation that
this function would return if it fails.)
1997-06-19 00:25:03 +00:00
wollman
29e9046de4 Fix definition of apm_power off (was suffering from cut&paste syndrome). 1997-06-15 02:19:40 +00:00
wollman
d3793afec0 When APM is configured, turn off the power when halting for good. 1997-06-15 02:03:03 +00:00
phk
8a36e4bbb4 Fix embarrasing typo that survived because I applied the wrong patch-
file.
Noticed by:	Eric Jones <ejon@psa.pencom.com>
1997-03-30 09:08:00 +00:00
phk
fc10d8f0c7 Sanitize APM a bit. Convert various #ifdef to id_flags instead.
You may want to add "flags 0x31" to apm0 if you have a lousy
implementation.  Read LINT.
1997-03-29 11:07:12 +00:00
phk
5cb2f4595c Try to talk to the APM BIOS with version 1.2 if possible. 1997-03-28 18:38:19 +00:00
kato
429cd71790 Makefile generates boths IBM-PC and PC-98 version of object code in
apm_init.inc.  The PC-98 version of object is included in `#ifdef
PC98'.

Pointed-out by:	URATA Shuichiro <s-urata@nmit.tmg.nec.co.jp>
1997-03-09 16:46:05 +00:00
peter
94b6d72794 Back out part 1 of the MCFH that changed $Id$ to $FreeBSD$. We are not
ready for it yet.
1997-02-22 09:48:43 +00:00
jkh
808a36ef65 Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
nate
544beb5705 > The extra include of <sys/time.h> is because apm uses microtime() and my
> <sys/param.h> doesn't include <sys/time.h>
>
> I removed the NAPM check since it's wasteful to check twice.  apmprobe()
> checks the unit number, and that's the right check.

Submitted by:	bde
1997-01-07 15:36:34 +00:00
nate
f22ea79edc - Cleanup up the driver (remove un-needed parameters, white-space,
etc..), plus add a better display suspend function.
- Changed the Copyright's to reflect the new 'jp.FreeBSD.org' email
  address.

Submitted by:	nate & HOSOKAWA, Tatsumi <hosokawa@jp.FreeBSD.org>
1997-01-06 06:02:03 +00:00
nate
abcc6bffc7 APM_DSVALUE_BUS is no longer with the addition of the correct fix to
machdep.c.  We no longer walk on the data segment the BIOS sets up.
1996-09-07 17:41:22 +00:00
phk
bca885205d Remove devconf, it never grew up to be of any use. 1996-09-06 23:09:20 +00:00
bde
de347e8ad8 Use (full) <> paths instead of ambiguous "" paths for headers not in
the current directory.
1996-08-28 17:54:17 +00:00
nate
7df809ca1e Add some comments explaining what APM_DSVALUE_BUG does no that I know
what it does and why it's needed.  Now I have to figure out how to fix
the bug. :)

[ No functional changes ]
1996-07-11 16:35:12 +00:00
nate
d62eaacadc Whee. Fix two bugs which ended up cancelling each other out.
apm_setup.s was storing apm_cs16_base and apm_cs32_base addresses in
each others slots, and apm.c was reversing the result so the bugs
cancelled out, but the code looked wrong.

No functional differences unfortunately.

Submitted by:	dave edmondson <davided@sco.com>
1996-07-10 15:09:48 +00:00
bde
097df5e884 Removed unused #includes of <i386/isa/icu.h> and <i386/isa/icu.h>. icu.h
is only used by the icu support modules and by a few drivers that know
too much about the icu (most only use it to convert `n' to `IRQn').  isa.h
is only used by ioconf.c and by a few drivers that know too much about
isa addresses (a few have to, because config is deficient).
1996-06-18 01:22:40 +00:00
nate
dc83deeffb Freudian slip. Change M_DEVBUG -> M_DEVBUF.
Submitted by:	 "Stephen F. Combs" <combssf@salem.ge.com>
1996-06-04 17:50:28 +00:00
nate
9fcfad930b Fix typo. in the APM_DSVALUE_BUG code that I missed.
Obtained from:	Someone on the mailing list (sorry, I forgot who)
1996-06-04 17:37:46 +00:00
nate
67c93bbe60 - This code adds some backwards compatability hacks for buggy APM BIOS
implementations, and synchronizes us with the Nomad's latest code.

This code is based on the Nomad code, but heavily hacked by me.

Reviewed by:	phk
Submitted by:	the 'Nomads'
1996-04-23 19:59:14 +00:00
nate
298d7dcd87 Adds the APM hooks into the generic pccard kernel files. With this code
in place device drivers can now register power-down/power-up routines so
that we can use common routines to power-up/power-down cards for
insert/removals, suspend/resume, etc..

Reviewed by:	phk
Submitted by:	the 'Nomads'
1996-04-23 16:03:08 +00:00
nate
32d5c84b4c - add apm to the GENERIC kernel (disabled by default), and add some comments
regarding apm to LINT
- Disabled the statistics clock on machines which have an APM BIOS and
  have the options "APM_BROKEN_STATCLOCK" enabled (which is default
  in GENERIC now)
- move around some of the code in clock.c dealing with the rtc to make
  it more obvios the effects of disabling the statistics clock

Reviewed by:	bde
1996-04-22 19:40:28 +00:00
nate
6eb9f2ef25 - Save/restore the FS data segment.
Reviewed by:	bde
1996-04-18 19:22:59 +00:00
nate
7dd4e08430 - Addition of my name to the APM Copyright
- More code cleanups
- #ifdef DEBUG debugging code
- More consistant printfs
- Better handling of the apm_int() assembly code (mostly from Bruce Evans)

Reviewed by:	bde
1996-04-18 19:21:47 +00:00
scrappy
415585985c Switched from using devfs_add_sw() to using devfs_add_swf()
Reviewed by:	julian@freebsd.org
1996-03-28 14:29:52 +00:00
nate
b74ac00a62 Add some comments on the APM specs, and make the APM 'idle/busy'
functions follow them.
1996-03-19 16:56:56 +00:00
nate
afd1f411f5 Call apm_int() instead of doing direct assembly calls even when we don't
care about the return value for consistency.
1996-03-19 16:48:38 +00:00
nate
b10555454e Added kernel compile time failure if more than one APM device is
configured.
1996-03-19 04:49:13 +00:00
nate
ebbb96df5d Always enable interrupts before calling the APM idle/busy routines.
Suggested by:	phk@FreeBSD.org
1996-03-19 04:40:03 +00:00
nate
2a6c56cfef Minor bugfixes from the recent PC-CARD release.
Submitted by:	hosokawa@mt.cs.keio.ac.jp and the rest of the Nomads
1996-03-18 23:30:14 +00:00
nate
f4fd38ee57 Grr, let's actually include <sys/devconf.h> so that DEVCONF support actually
works.
1996-03-18 22:47:16 +00:00
nate
4995ce37e8 Whoops, forgot the line that sets the default state in devfs. 1996-03-18 22:40:57 +00:00
nate
4c7fdd4f2e Devfs support.
Submitted by:   hosokawa@mt.cs.keio.ac.jp and the rest of the Nomads

Cleanup.
1996-03-18 22:29:48 +00:00
nate
c7f74c6b51 Removed support for multiple APM devices. 1996-03-18 21:58:22 +00:00
nate
986c9f5c3a Return the status of the APM support (enabled/disabled) with the
APM_GETINFO ioctl.
1996-03-13 00:42:56 +00:00
nate
069131e0ec Removed more APM_SLOWSTART code and re-enabled some functions which
didn't require APM_SLOWSTART to be defined.
1996-03-12 21:51:58 +00:00
nate
1357ea6673 Fix some minor typo's in the comments. 1996-03-12 21:23:56 +00:00
nate
0ac561df48 Always initialize master_softc. This avoids panics in the idle loop due
to unitialized data if the APM support is compiled in and the probe
fails.
1996-03-12 06:09:34 +00:00
nate
d3d6c3d3ef Do a APM BIOS dis-connect before attempting to do a 32-bit connection
just in case a connection already existed.

Also, a minor optimization in the code which determins if a APM BIOS exists.

Reviewed by:	phk

This is based on the APM-0.5 patch for Linux, but written entirely by me.
1996-03-11 21:55:18 +00:00
nate
4c7f7450e5 Removed conditionals on BDE_DEBUGGER around the loading for the IDT
since it's necessary for interrupt processing to be enabled.  Modify
comment to reflect this condition.

Submitted by:	bde
1996-03-11 21:42:52 +00:00
nate
878cd16481 Bring in most of Bruce's prot_to_real() changes into the APM BIOS
startup code.

Reviewed by:  bde
1996-03-11 06:48:57 +00:00
mpp
f3dd75a38d Fix a bunch of spelling errors in the comment fields of
a bunch of system include files.
1996-01-30 23:02:38 +00:00
bde
5865dfdfe7 Finished removing MACH_KERNEL stuff. 1995-12-27 16:16:02 +00:00
bde
01f94ecaac Fixed staticizing. Some functions aren't static but depend on
the undocumented previously unLINTed option `APM_SLOWSTART'.
1995-12-25 07:38:47 +00:00
phk
a267c8b3d9 Cleanup. 1995-12-22 13:08:27 +00:00