mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Oliver Neukum <oneukum@suse.de>
To: Alan Cox <alan@linux.intel.com>
Cc: linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] hmc6352: Add driver for the HMC6352 compass
Date: Wed, 16 Jun 2010 14:43:45 +0200	[thread overview]
Message-ID: <201006161443.45375.oneukum@suse.de> (raw)
In-Reply-To: <20100616121534.26294.12540.stgit@localhost.localdomain>

Am Mittwoch, 16. Juni 2010 14:16:14 schrieb Alan Cox:
> +       msleep(10); /* sending 0x41 cmd we need to wait for 7-10 milli seconds */
> +       ret = i2c_transfer(client->adapter, msg1, 1);
> +       if (ret != 1) {
> +               dev_warn(dev, "i2c read data cmd failed\n");
> +               return ret;
> +       }
> +       ret_val = i2c_data[0];
> +       ret_val = ((ret_val << 8) | i2c_data[1]);

Please use the correct macro for this conversion.

	Regards
		Oliver

  reply	other threads:[~2010-06-16 12:43 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-16 12:16 Alan Cox
2010-06-16 12:43 ` Oliver Neukum [this message]
2010-06-17 11:20   ` Alan Cox
2010-06-17 12:26     ` Oliver Neukum
2010-06-17 12:46       ` Alan Cox
2010-06-16 13:10 ` Jean Delvare
2010-06-17 11:50   ` Alan Cox
2010-06-17 12:19     ` Jonathan Cameron
2010-06-17 13:14       ` Alan Cox
2010-06-17 14:52         ` Jean Delvare
2010-06-17 15:17           ` Alan Cox
2010-06-17 15:56             ` Jean Delvare
2010-06-16 14:46 ` Jonathan Cameron
2010-06-17 11:34   ` Alan Cox

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201006161443.45375.oneukum@suse.de \
    --to=oneukum@suse.de \
    --cc=alan@linux.intel.com \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome