[PATCH 35/39] pcmcia: deprecate CS_BAD_TUPLE
Larry Finger
Larry.Finger at lwfinger.net
Wed Aug 20 17:01:54 EDT 2008
Dominik Brodowski wrote:
> CS_BAD_TUPLE was used to denote a bad tuple being passed to the parse
> function. Therefore, replace it with -EINVAL and a verbose message.
>
> Signed-off-by: Dominik Brodowski <linux at dominikbrodowski.net>
> ---
> drivers/pcmcia/cistpl.c | 96 +++++++++++++++++++++--------------------
> drivers/pcmcia/ds.c | 1 -
> drivers/pcmcia/pcmcia_ioctl.c | 2 -
> include/pcmcia/cs.h | 2 +-
> 4 files changed, 50 insertions(+), 51 deletions(-)
>
--- snip a bunch ---
> switch (tuple->TupleCode) {
> case CISTPL_DEVICE:
> case CISTPL_DEVICE_A:
> @@ -1400,6 +1400,8 @@ int pccard_parse_tuple(tuple_t *tuple, cisparse_t *parse)
> ret = -EINVAL;
> break;
> }
> + if (ret)
> + cs_dbg(s, 0, "parse_tuple failed %d\n", ret);
This routine fails to compile with debugging enabled because "s" has
never been declared. The fix required adding the socket as an argument
for pccard_parse_tuple, which required a change in the wrapper macro,
etc. The revised patch is attached.
Larry
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: pcmcia_35_39
Url: http://lists.infradead.org/pipermail/linux-pcmcia/attachments/20080820/9f329774/attachment-0001.pl
More information about the linux-pcmcia
mailing list