History log of /src/sys/dev/i2c/ibmhawk.c |
Revision | | Date | Author | Comments |
1.9 |
| 15-May-2020 |
maxv | hardclock_ticks -> getticks()
|
1.8 |
| 03-Sep-2018 |
riastradh | Rename min/max -> uimin/uimax for better honesty.
These functions are defined on unsigned int. The generic name min/max should not silently truncate to 32 bits on 64-bit systems. This is purely a name change -- no functional change intended.
HOWEVER! Some subsystems have
#define min(a, b) ((a) < (b) ? (a) : (b)) #define max(a, b) ((a) > (b) ? (a) : (b))
even though our standard name for that is MIN/MAX. Although these may invite multiple evaluation bugs, these do _not_ cause integer truncation.
To avoid `fixing' these cases, I first changed the name in libkern, and then compile-tested every file where min/max occurred in order to confirm that it failed -- and thus confirm that nothing shadowed min/max -- before changing it.
I have left a handful of bootloaders that are too annoying to compile-test, and some dead code:
cobalt ews4800mips hp300 hppa ia64 luna68k vax acorn32/if_ie.c (not included in any kernels) macppc/if_gm.c (superseded by gem(4))
It should be easy to fix the fallout once identified -- this way of doing things fails safe, and the goal here, after all, is to _avoid_ silent integer truncations, not introduce them.
Maybe one day we can reintroduce min/max as type-generic things that never silently truncate. But we should avoid doing that for a while, so that existing code has a chance to be detected by the compiler for conversion to uimin/uimax without changing the semantics until we can properly audit it all. (Who knows, maybe in some cases integer truncation is actually intended!)
|
1.7 |
| 16-Jun-2018 |
thorpej | branches: 1.7.2; More cleanup to i2c autoconfiguration:
- Get all of the drivers onto the new match quality constants. - Introduce a new helper function, iic_use_direct_match(), that has all of the logic for direct-config matching. If it returns true, the driver returns the match result (which may be 0). If it returns false, the driver does indirect-config matching. - iic_compat_match() now returns a weighted match quality; matches to lower-indexed "compatible" device property are more-specific matches, and return a better match quality accordingly.
|
1.6 |
| 06-Jun-2018 |
maya | Remove duplicate ;
|
1.5 |
| 09-May-2018 |
thorpej | The probe this driver uses is potentially destructive; at the very least, filter on the I2C address the device is expected at before we unleash its fury.
|
1.4 |
| 14-Jul-2016 |
msaitoh | branches: 1.4.16; Use aprint_error() instead of aprint_normal() on error.
|
1.3 |
| 21-Jun-2011 |
hannken | branches: 1.3.12; 1.3.30; Make sure sensor state is valid before calling sysmon_envsys_sensor_attach().
Ok: Paul Goyette <pgoyette@netbsd.org>
|
1.2 |
| 14-Feb-2011 |
hannken | branches: 1.2.2; 1.2.4; 1.2.8; ibmhawk_set: No need to set states ENVSYS_SWARNxxx, sysmon will do it.
|
1.1 |
| 14-Feb-2011 |
hannken | Initial implementation of ibmhawk(4) driver for sensors behind the IBM Hawk on-board Integrated Systems Management Processor found on some eServers.
Tested on an IBM eServer x335.
|
1.2.8.2 |
| 06-Jun-2011 |
jruoho | Sync with HEAD.
|
1.2.8.1 |
| 14-Feb-2011 |
jruoho | file ibmhawk.c was added on branch jruoho-x86intr on 2011-06-06 09:07:49 +0000
|
1.2.4.2 |
| 05-Mar-2011 |
rmind | sync with head
|
1.2.4.1 |
| 14-Feb-2011 |
rmind | file ibmhawk.c was added on branch rmind-uvmplock on 2011-03-05 20:53:10 +0000
|
1.2.2.2 |
| 17-Feb-2011 |
bouyer | Sync with HEAD
|
1.2.2.1 |
| 14-Feb-2011 |
bouyer | file ibmhawk.c was added on branch bouyer-quota2 on 2011-02-17 12:00:12 +0000
|
1.3.30.1 |
| 05-Oct-2016 |
skrll | Sync with HEAD
|
1.3.12.1 |
| 03-Dec-2017 |
jdolecek | update from HEAD
|
1.4.16.3 |
| 06-Sep-2018 |
pgoyette | Sync with HEAD
Resolve a couple of conflicts (result of the uimin/uimax changes)
|
1.4.16.2 |
| 25-Jun-2018 |
pgoyette | Sync with HEAD
|
1.4.16.1 |
| 21-May-2018 |
pgoyette | Sync with HEAD
|
1.7.2.1 |
| 10-Jun-2019 |
christos | Sync with HEAD
|