From: Jonathan Cameron <jic23@kernel.org>
To: Octavian Purdila <octavian.purdila@intel.com>,
Jonathan Cameron <jic23@jic23.retrosnub.co.uk>
Cc: Fengguang Wu <fengguang.wu@intel.com>,
"linux-iio@vger.kernel.org" <linux-iio@vger.kernel.org>,
kbuild-all@01.org
Subject: Re: [iio:testing 10/10] ERROR: "__divdi3" [drivers/iio/accel/bmc150-accel.ko] undefined!
Date: Sun, 29 Mar 2015 11:59:58 +0100 [thread overview]
Message-ID: <5517DB2E.8060903@kernel.org> (raw)
In-Reply-To: <CAE1zot+PyXFOxP-EoYCjPgJ5T8eMKQPcAwVRjBmrpKwcDtbbrA@mail.gmail.com>
On 29/03/15 00:15, Octavian Purdila wrote:
> On 28 Mar 2015 16:18, "Jonathan Cameron" <jic23@jic23.retrosnub.co.uk> wrote:
>>
>> On 28/03/15 13:02, kbuild test robot wrote:
>>> tree: git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git testing
>>> head: 5e02849a682600c1663a333f95f0388d1c536108
>>> commit: 5e02849a682600c1663a333f95f0388d1c536108 [10/10] iio: bmc150_accel: add support for hardware fifo
>>> config: m68k-allmodconfig (attached as .config)
>>> reproduce:
>>> wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
>>> chmod +x ~/bin/make.cross
>>> git checkout 5e02849a682600c1663a333f95f0388d1c536108
>>> # save the attached .config to linux build tree
>>> make.cross ARCH=m68k
>>>
>>> All error/warnings:
>>>
>>>>> ERROR: "__divdi3" [drivers/iio/accel/bmc150-accel.ko] undefined!
>> Oops, missed that. I think we can use a simple do_div for computing the sample_period
>> (which included 64bit / 8 bit).
>>
>> Will push out a patch to the testing branch to see if they autobuilders are
>> happy with it then fix up the driver properly if they are.
>>
>> diff --git a/drivers/iio/accel/bmc150-accel.c b/drivers/iio/accel/bmc150-accel.c
>> index c639489671bb..d5e103b208ba 100644
>> --- a/drivers/iio/accel/bmc150-accel.c
>> +++ b/drivers/iio/accel/bmc150-accel.c
>> @@ -1002,7 +1002,8 @@ static int __bmc150_accel_fifo_flush(struct iio_dev *indio_dev,
>> * To avoid this issue we compute the actual sample period ourselves
>> * based on the timestamp delta between the last two flush operations.
>> */
>> - sample_period = (data->timestamp - data->old_timestamp) / count;
>> + sample_period = (data->timestamp - data->old_timestamp);
>> + do_div(sample_period, count);
>> tstamp = data->timestamp - (count - 1) * sample_period;
>>
>> if (samples && count > samples)
>>
>
> Oops, sorry about this Jonathan and thank you for fixing it so quickly.
Except I just changed it from a build fail to a warning. I think for do_div it
needs to be uint64 so just pushed that build test out.
All warnings:
drivers/iio/accel/bmc150-accel.c: In function '__bmc150_accel_fifo_flush':
>> drivers/iio/accel/bmc150-accel.c:1006:2: warning: comparison of distinct pointer types lacks a cast [enabled by default]
vim +1006 drivers/iio/accel/bmc150-accel.c
>
> One more thing, I marked the new sysfs entries for 4.2, but it seems
> that these might make it in 4.1. Should I send a patch to correct
> this?
>
prev parent reply other threads:[~2015-03-29 11:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <201503282121.NkeMOw9e%fengguang.wu@intel.com>
2015-03-28 14:18 ` [iio:testing 10/10] ERROR: "__divdi3" [drivers/iio/accel/bmc150-accel.ko] undefined! Jonathan Cameron
2015-03-29 0:15 ` Octavian Purdila
2015-03-29 10:59 ` Jonathan Cameron [this message]
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=5517DB2E.8060903@kernel.org \
--to=jic23@kernel.org \
--cc=fengguang.wu@intel.com \
--cc=jic23@jic23.retrosnub.co.uk \
--cc=kbuild-all@01.org \
--cc=linux-iio@vger.kernel.org \
--cc=octavian.purdila@intel.com \
/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 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.