Skip to content
Commit 6ad124d5 authored by Ian Abbott's avatar Ian Abbott Committed by Greg Kroah-Hartman
Browse files

staging: comedi: plx9080.h: define PLX_<REG>_TO_<FIELD>(r) macros



Various macros in "plx9080.h" take the form `PLX_<REG>_<FIELD>(x)`,
where `<REG>` is a register name, `<FIELD>` is a field within the
register, and `x` is a value for the field specified by the caller.  The
macros construct a partial register register with the specified field
value placed in the appropriate bits of the register value, and other
bits of the register value zeroed.  Add corresponding macros of the form
`PLX_<REG>_TO_<FIELD>(r)` that extract a field value from a specified
register values.  Remove macros of the form `PLX_<REG>_<FIELD>_SHIFT`
that specified the bit position of a field within a register value as
they are no longer useful.

Signed-off-by: default avatarIan Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5bf9bd8d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment