All of lore.kernel.org
 help / color / mirror / Atom feed
* pcf8591 range list syntax
@ 2004-11-12 14:25 Karel Kulhavy
  2004-11-14  4:22 ` Randy.Dunlap
  0 siblings, 1 reply; 2+ messages in thread
From: Karel Kulhavy @ 2004-11-12 14:25 UTC (permalink / raw)
  To: linux-kernel

Hello

modinfo pcf8591 in 2.6.8.1 says:
"parm:           probe_range:List of adapter,start-addr,end-addr triples to
scan additionally "

when I call modprobe pcf8591 probe_range=..., what is the syntax of the list?
Are the addresses in decimal (0,255) or hexa (0,ff) or variable base
(0,0xff)?

When I want to specify 2 triples say 0,0,8 and 1,4,6 , is it
probe_range=0,0,8,1,4,6 or probe_range={0,0,8},{1,4,6} or something like
this or something completely different?

Cl<


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: pcf8591 range list syntax
  2004-11-12 14:25 pcf8591 range list syntax Karel Kulhavy
@ 2004-11-14  4:22 ` Randy.Dunlap
  0 siblings, 0 replies; 2+ messages in thread
From: Randy.Dunlap @ 2004-11-14  4:22 UTC (permalink / raw)
  To: Karel Kulhavy; +Cc: linux-kernel

Karel Kulhavy wrote:
> Hello
> 
> modinfo pcf8591 in 2.6.8.1 says:
> "parm:           probe_range:List of adapter,start-addr,end-addr triples to
> scan additionally "
> 
> when I call modprobe pcf8591 probe_range=..., what is the syntax of the list?
> Are the addresses in decimal (0,255) or hexa (0,ff) or variable base
> (0,0xff)?
> 
> When I want to specify 2 triples say 0,0,8 and 1,4,6 , is it
> probe_range=0,0,8,1,4,6 or probe_range={0,0,8},{1,4,6} or something like
> this or something completely different?

Wow.  Good questions.  Those I2C module param. macros are fugly.

probe_range=list_of_up_to_48_entries
It's just a comma-separated list.
Don't put braces or parens or anything around the "triples".
E.g.,
probe_range=0,0,8,1,4,6
(that's 6 entries in the 'probe_range' list, not 2)

Parameter conversion is done by calling simple_strtoul (in this case),
since the parameter type is ushort.  The specified number base
is 0, which means base 10, unless some other base is specified,
with 0x or 0X meaning hex, or a leading 0 without an [xX]
following it means octal.

-- 
~Randy

PS:  This is just from scanning the source code.  I don't
know the I2C code.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-11-14  4:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-11-12 14:25 pcf8591 range list syntax Karel Kulhavy
2004-11-14  4:22 ` Randy.Dunlap

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.