Commit Graph

23 Commits

Author SHA1 Message Date
David Bright
9e33968b60 asmc: Add support for Mac mini 2,1
PR:		235798
Submitted by:	Trev <fbsdbugs4@sentry.org>
Reported by:	Trev <fbsdbugs4@sentry.org>
MFC after:	1 week
2019-02-25 21:59:01 +00:00
David Bright
9f0bfc517c asmc: Add support for Mac mini 4,1 (Mid-2010)
MFC after:	1 week
2019-01-06 23:43:12 +00:00
David Bright
98ae4866ba asmc: Patch to add MacBook Pro 9,2 support
PR:		211513
Submitted by:	William Theesfeld Jr <wtheesfeld@mailbox.org>
Reported by:	William Theesfeld Jr <wtheesfeld@mailbox.org>
MFC after:	1 week
2019-01-04 18:21:49 +00:00
David Bright
39a8ee1351 asmc: Add support for MacPro1,1
PR:		203431
Submitted by:	jjr@alisa.org & holindho@saunalahti.fi
Reported by:	jjr@alisa.org
MFC after:	1 week
2018-12-19 16:45:37 +00:00
David Bright
71b475e7dd asmc: Add support for mid-2011 Macmini 5,2
PR:		225911
Submitted by:	trev <fbsdbugs4@sentry.org>
Reported by:	trev <fbsdbugs4@sentry.org>
MFC after:	1 week
2018-12-17 17:21:45 +00:00
David Bright
09ff71d357 asmc: Add Support for Macbook Pro 8,1
PR:		217505
Submitted by:	John O. Brickley <obryan.brickley@gmail.com>, updated by Maciej Pasternacki <maciej@pasternacki.net>
Reported by:	John O. Brickley <obryan.brickley@gmail.com>
MFC after:	1 week
2018-12-12 13:43:55 +00:00
David Bright
081954d3a2 asmc: Add Support for MacBookAir 7,1 and 7,2
PR:		226172
Submitted by:	James Wright <james.wright@jigsawdezign.com>
Reported by:	James Wright <james.wright@jigsawdezign.com>
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D18396
2018-12-11 16:35:59 +00:00
Ed Maste
95320b99a5 asmc: update temperature sensor name/description
PR:		225911
Submitted by:	Trev <fbsdbugs4 at sentry.org>
MFC after:	1 week
2018-03-08 18:52:47 +00:00
Pedro F. Giffuni
718cf2ccb9 sys/dev: further adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.
2017-11-27 14:52:40 +00:00
Adrian Chadd
109e2d29cc [asmc] Add support for MacBook Pro 11,2
This patch will add support for MacBookPro 11.2.
For the macros, the MBP11_* macros (for the existing MacBookPro11.3) did not
match so they have been renamed to MBP113_* and a new MBP112_* has been
added (modified copy of MBP11_*).

Some trailing whitespaces may have been removed automatically.

PR:		kern/214836
Obtained from:	Johannes Lundberg <johannes@brilliantservice.co.jp
2017-02-17 18:49:18 +00:00
Adrian Chadd
31ae3b070d [asmc] Add support for MacBookPro5,1
Tested by:	Johannes Lundberg <johannes@brilliantservice.co.jp>
PR:		kern/209179
Submitted by:	Thomas Brierley <tomxor@gmail.com>
2016-05-03 17:11:33 +00:00
Adrian Chadd
108e307680 [asmc] add support for more models and restore keyboard backlight after resume.
This patch adds support for restoring backlight after resume and adds models
Macbook3,1
MacbookAir5,1
MacbookAir5,2

It also incorporates fixes for bug #175260, bug #203610 and bug #203512
so those can be closed if this patch is applied.

PR:		kern/209156
PR: kern/175260
PR: kern/203610
PR: kern/203512
Submitted by:	Johannes Lundberg <johannes@brilliantservice.co.jp>
2016-05-02 19:15:16 +00:00
Rui Paulo
447666f08b Improvements to asmc(4):
1. changed the code so that 2**16 keys are supported
2. changed the number of possible fans in a system from 2 to 6
3. added write support for some fan sysctls
4. added a new sysctl which shows the ID of the fan
5. added four more apple models with their temperature keys
6. changed the maxnumber of temperature keys from 36 to 80
7. replaced several fixed buf sizes to sizeof buf

Obtained from:	Denis Ahrens denis at h3q.com
MFC after:	4 weeks
2014-09-22 16:20:38 +00:00
Gavin Atkinson
764442e03d Add support to asmc(4) for Macmini 3,1.
PR:		190195
Submitted by:	fbsdbugs2 sentry.org
MFC after:	1 week
Relnotes:	yes
2014-07-05 21:34:37 +00:00
Rui Paulo
1269f4d431 Make the sudden motion sensor work on older models and add a bit of
debugging.

Submitted by:	Christoph Langguth <christoph at rosenkeller.org>
MFC after:	1 week
2009-09-14 11:46:43 +00:00
Rui Paulo
be80e49a01 Add support for MacBook4,1.
Submitted by:	Christoph Langguth <christoph at rosenkeller.org>
MFC after:	2 weeks
Approved by:	re (kib)
2009-06-26 10:23:17 +00:00
Rui Paulo
941f9f10b2 Add support for MacBook Air. (not tested)
Obtained from:	mactel-linux
2008-09-07 18:15:34 +00:00
Rui Paulo
d8246db039 Match the Mac Pro with 8 cores. This machine reports 35 temperature
sensors and some fans.
As I don't own this machine, I could not test this patch.

Obtained from:	applesmc Linux driver.
2008-04-12 12:04:09 +00:00
Rui Paulo
b75dfbe80d Actually, I was looking at the wrong Linux .c file. Set INIT2 to its
previous value.
While there, lower the delay for the misterious key.
2008-04-07 12:58:43 +00:00
Rui Paulo
4fb9bf66ad * Add missing #else in the #ifdef DEBUG section.
* Fix the login in asmc_init().
* Change the INIT2 constant to reflect the same change in the Linux driver.
2008-04-07 12:09:59 +00:00
Rui Paulo
2208c50409 "Prettyfy" numbers in hexadecimal. No functional change. 2008-04-07 11:38:42 +00:00
Rui Paulo
4470f0f388 The SMC is represented on the acpi tables, so we can completely remove
dependency on isa. We are now an acpi child.

Also:
	* Add compile time debugging activation
	* Increase the delay for the SMS init flag.
2008-04-07 11:22:12 +00:00
Rui Paulo
32a8088fef Driver for the Apple System Management Console (SMC). This hardware is
present on the MacBook, MacBook Pro, and Intel MacMini.

This driver exports information via sysctl in its private sysctl tree
dev.asmc.*. You can get information about temperatures, fan speeds, the
keyboard light sensor and the Sudden Motion Sensor (SMS).
The SMS is very useful to park the disk heads when the laptop is
moved. Basically, the SMS is setup so that, under movement, we get an
interrupt on irq 6 and a devd notification is sent.

Sponsored by:	 Google Summer of Code 2007
Approved by:	 njl (mentor)
Reviewed by:	 attilio (previous version, but very similar), jhb (interrupt
	 	 specific review)
2007-11-07 20:05:13 +00:00