Skip to contentSkip to conversation

drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may be

PATCH In review Fengguang Wu 2 participants 3 messages Jul 13, 2012 Kernel janitors

lore
Share & tools
lore
#0 lore raw

PATCH 86/99 drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may be

Hi Lars-Peter,

There are compile warnings in

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-next
head:   bd972ff3176caf91a49d1d754848c3f6c5435328
commit: 3879089ba3421bc8136025837b1a532729643371 [86/99] staging:iio:max1363: Don't free uninitialized variable

All warnings:

drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may be used uninitialized in this function [-Wmaybe-uninitialized]

vim +97 drivers/staging/iio/adc/ad7298_ring.c

    94							 indio_dev->masklength); i++)
    95			buf[i] = be16_to_cpu(st->rx_buf[i]);
    96	
Quoted 1 line

97 indio_dev->buffer->access->store_to(ring, (u8 *)buf, time_ns);

    98	
    99	done:

100 iio_trigger_notify_done(indio_dev->trig);

---
0-DAY kernel build testing backend Open Source Technology Centre
Fengguang Wu <[email protected]> Intel Corporation

#1 lore raw

Re: [staging:staging-next 86/99] drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may

Quoted 4 lines · Fengguang Wu

Hi Lars-Peter,

There are compile warnings in

Quoted 8 lines
tree:   git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-next
head:   bd972ff3176caf91a49d1d754848c3f6c5435328
commit: 3879089ba3421bc8136025837b1a532729643371 [86/99] staging:iio:max1363: Don't free uninitialized variable

All warnings:

drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may be used uninitialized in this function [-Wmaybe-uninitialized]

Hi,

I don't think the warning is caused by that commit. The file in question is not affected by it.

Quoted 12 lines

vim +97 drivers/staging/iio/adc/ad7298_ring.c

    94							 indio_dev->masklength); i++)
    95			buf[i] = be16_to_cpu(st->rx_buf[i]);
    96	
Quoted 1 line

97 indio_dev->buffer->access->store_to(ring, (u8 *)buf, time_ns);

    98	
    99	done:
   100		iio_trigger_notify_done(indio_dev->trig);

---
0-DAY kernel build testing backend Open Source Technology Centre
Fengguang Wu <[email protected]> Intel Corporation

#2 lore raw

Re: [staging:staging-next 86/99] drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may

In reply to Fengguang Wu
Quoted 11 lines · Lars-Peter Clausen
Quoted 10 lines · Fengguang Wu

Hi Lars-Peter,

There are compile warnings in

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-next
head:   bd972ff3176caf91a49d1d754848c3f6c5435328
commit: 3879089ba3421bc8136025837b1a532729643371 [86/99] staging:iio:max1363: Don't free uninitialized variable

All warnings:

Quoted 7 lines
Quoted 2 lines

drivers/staging/iio/adc/ad7298_ring.c:97:37: warning: 'time_ns' may be used uninitialized in this function [-Wmaybe-uninitialized]

Hi,

I don't think the warning is caused by that commit. The file in question is not affected by it.

You are right. The real bad commit is this:

commit 7c31b984c4d119d0e32a1696fd4ca6b506a73d10

Author: Michael Hennerich <[email protected]>
Date:   Thu Feb 24 12:32:45 2011 +0100

IIO: ADC: New driver for the AD7298 8-channel SPI ADC

Thanks,
Fengguang