Re: CVS commit: src/sys/dev/i2c

2022-11-24 Thread Brad Spencer
Taylor R Campbell writes: [snip] > The issue here isn't the duration of the delay -- just the mechanism. > Sleeping for 35ms with kpause(9) is fine, but busy-waiting on the CPU > for 35ms with delay(9) is not (unless HZ is set to something absurdly > low like 10 instead of the usual 100, but I d

Re: CVS commit: src/sys/dev/i2c

2022-11-24 Thread Taylor R Campbell
> Date: Wed, 23 Nov 2022 01:42:13 -0500 > From: Brad Spencer > > Simon Burge writes: > > > + delay(35000); > > > > This will spin for 35 milliseconds (per sensor read if I read this > > correctly). Can you please look at using kpause(9) for this delay? > > See some other i2c drivers for

Re: CVS commit: src/sys/dev/i2c

2022-11-22 Thread Brad Spencer
Simon Burge writes: > Hi Brad, > >> Module Name: src >> Committed By:brad >> Date:Tue Nov 22 19:40:31 UTC 2022 >> >> Modified Files: >> >> src/sys/dev/i2c: bmx280.c >> >> Log Message: >> >> Read the datasheet more closely and put in some delays. The chip will >> just

Re: CVS commit: src/sys/dev/i2c

2022-11-22 Thread Simon Burge
Hi Brad, > Module Name: src > Committed By: brad > Date: Tue Nov 22 19:40:31 UTC 2022 > > Modified Files: > > src/sys/dev/i2c: bmx280.c > > Log Message: > > Read the datasheet more closely and put in some delays. The chip will > just return junk if the wait is not long enough to al

Re: CVS commit: src/sys/dev/i2c

2020-07-12 Thread Kimmo Suominen
Hi Michael, Perhaps your commit missed some changes? The code no longer compiles. Cheers, + Kimmo /p/netbsd/cvs/src/sys/dev/i2c/dbcool.c: In function 'dbcool_attach': /p/netbsd/cvs/src/sys/dev/i2c/dbcool.c:778:4: error: 'struct dbcool_softc' has no member named 'sc_prop' sc->sc_prop = args->

Re: CVS commit: src/sys/dev/i2c

2019-12-24 Thread Ryo ONODERA
Hi, "Jason R Thorpe" writes: > Module Name: src > Committed By: thorpej > Date: Sun Dec 22 16:44:35 UTC 2019 > > Modified Files: > src/sys/dev/i2c: ihidev.c ihidev.h > > Log Message: > The hid-over-i2c spec specifies that compliant devices use level-sensitive > interrupts. Howeve

Re: CVS commit: src/sys/dev/i2c

2018-12-14 Thread Jason Thorpe
> On Dec 14, 2018, at 2:05 PM, Michael Lorenz wrote: > > Module Name: src > Committed By: macallan > Date: Fri Dec 14 22:05:36 UTC 2018 > > Modified Files: > src/sys/dev/i2c: ds1307.c files.i2c > > Log Message: > add options DSRTC_YEAR_START_2K for machines which use 2000 and

Re: CVS commit: src/sys/dev/i2c

2018-06-30 Thread Jason Thorpe
> On Jun 30, 2018, at 10:50 AM, Frank Kardel wrote: > > Hi Jason ! > > It is not so odd as your comment suggests. The I2C address is stored in the > device EEPROM and perfectly survives a power off. Ah! If the data sheet mentions this fact, I completely missed it. I'm afraid I probably did

Re: CVS commit: src/sys/dev/i2c

2018-06-30 Thread Frank Kardel
Hi Jason ! It is not so odd as your comment suggests. The I2C address is stored in the device EEPROM and perfectly survives a power off. All we need to be able to is to explicitly configure the device at a different address. I hope this capability was not disabled with this check-in as that

Re: CVS commit: src/sys/dev/i2c

2018-06-07 Thread Valery Ushakov
On Thu, Jun 07, 2018 at 13:30:49 +, Jason R Thorpe wrote: > ? iic_search() chooses a ?probe strategy? based on the Please, can you disable smart punctuation. -uwe

Re: CVS commit: src/sys/dev/i2c

2017-08-29 Thread Jared McNeill
On Tue, 29 Aug 2017, Manuel Bouyer wrote: But it depends on the order in which the devices are probed/attached, isn't it ? The MD FDT code hooks up the powerdown handler very early, in initarm: https://nxr.netbsd.org/xref/src/sys/arch/evbarm/fdt/fdt_machdep.c#392

Re: CVS commit: src/sys/dev/i2c

2017-08-29 Thread Manuel Bouyer
On Tue, Aug 29, 2017 at 02:59:58PM -0300, Jared McNeill wrote: > I'm not opposed to having a compile time option or sysctl -- but if we do I > think we should try to make it MI. In theory an ACPI capable x86 board could > have this problem as well.. Sure. The problem is more which poweroff callbac

Re: CVS commit: src/sys/dev/i2c

2017-08-29 Thread Jared McNeill
On Tue, 29 Aug 2017, Manuel Bouyer wrote: I'd like to have a way to disable this (a compile-time option would be OK for me). On evaluation boards (like cubieboard, or olimex lime2), you may have a power button on the board itself but you don't have a way to add an external power button (e.g. if

Re: CVS commit: src/sys/dev/i2c

2017-08-29 Thread Manuel Bouyer
On Tue, Aug 29, 2017 at 10:10:54AM +, Jared D. McNeill wrote: > Module Name: src > Committed By: jmcneill > Date: Tue Aug 29 10:10:54 UTC 2017 > > Modified Files: > src/sys/dev/i2c: axp20x.c axp20xvar.h > > Log Message: > Add powerdown support and hook it in to FDT I'd like to

Re: CVS commit: src/sys/dev/i2c

2014-03-22 Thread David Holland
On Mon, Mar 17, 2014 at 03:57:56PM +, Nick Hudson wrote: > Modified Files: > src/sys/dev/i2c: x1226.c > > Log Message: > Fix build. > > Hi dh! Oops, I thought I'd caught all of those. (I did most of the bulk editing with a macro) -- David A. Holland dholl...@netbsd.org

Re: CVS commit: src/sys/dev/i2c

2013-08-06 Thread Paul Goyette
There are quite flexible fan control options as well as just monitoring, but it is not clear to me how best to export that function to userspace. We really don't have any suitable interface for this just yet. For the dbcool(4) driver, I just exposed everything via sysctl(8) nodes... The c

Re: CVS commit: src/sys/dev/i2c

2012-07-29 Thread Matt Thomas
On Jul 28, 2012, at 10:52 PM, David Holland wrote: > On Sat, Jul 28, 2012 at 10:22:46PM -0700, Matt Thomas wrote: Modified Files: src/sys/dev/i2c: g760a.c Log Message: Use (void *) instead of (type **) which gcc complains about. >>> >>> At least one of these casts is

Re: CVS commit: src/sys/dev/i2c

2012-07-28 Thread David Holland
On Sat, Jul 28, 2012 at 10:22:46PM -0700, Matt Thomas wrote: > >> Modified Files: > >> src/sys/dev/i2c: g760a.c > >> > >> Log Message: > >> Use (void *) instead of (type **) which gcc complains about. > > > > At least one of these casts is discarding const and writing to the > > const o

Re: CVS commit: src/sys/dev/i2c

2012-07-28 Thread Matt Thomas
On Jul 28, 2012, at 9:29 PM, David Holland wrote: > On Sat, Jul 28, 2012 at 11:03:47PM +, Matt Thomas wrote: >> Modified Files: >> src/sys/dev/i2c: g760a.c >> >> Log Message: >> Use (void *) instead of (type **) which gcc complains about. > > At least one of these casts is discarding c

Re: CVS commit: src/sys/dev/i2c

2012-07-28 Thread David Holland
On Sat, Jul 28, 2012 at 11:03:47PM +, Matt Thomas wrote: > Modified Files: > src/sys/dev/i2c: g760a.c > > Log Message: > Use (void *) instead of (type **) which gcc complains about. At least one of these casts is discarding const and writing to the const object returned by sysctl_cr

Re: CVS commit: src/sys/dev/i2c

2011-10-02 Thread Jared McNeill
You forgot to make the iic driver detachable, modunload iic will panic I think. -Original Message- From: Marc Balmer Sent: Sunday, October 02, 2011 7:38 AM Newsgroups: gmane.os.netbsd.devel.cvs.full To: source-changes-full-qavaossjccednm+yrof...@public.gmane.org Subject: CVS commit: s

Re: CVS commit: src/sys/dev/i2c

2011-01-21 Thread Izumi Tsutsui
> Added Files: > src/sys/dev/i2c: pcf8563.c pcf8563reg.h > > Log Message: > Add pcf8563rtc(4), yet another I2C real time clock. It looks better to use todr_[gs]ettime_ymdhms rather than todr_[gs]ettime like rs5c372.c. --- Izumi Tsutsui