d, 97 insertions(+), 1 deletion(-)
> create mode 100644 scripts/coccinelle/misc/add_namespace.cocci
> create mode 100644 scripts/nsdeps
[]
> +if [ "$SPATCH_VERSION_NUM" -lt "$SPATCH_REQ_VERSION_NUM" ] ; then
> +echo 'spatch needs to be version 1.06 or higher
.
Currently pressure is reported in hectopascal(hPa) and relative humidity
in percent. Hence fix this ABI mismatch conforming to the standard ABI.
Fixes: 1b3bd8592780 ("iio: chemical: Add support for Bosch BME680 sensor")
Signed-off-by: Himanshu Jha
---
While cleaning this mess I wonder
Use recently introduced devm_platform_ioremap_resource
helper which wraps platform_get_resource() and
devm_ioremap_resource() together. This helps produce much
cleaner code and remove local `struct resource` declaration.
Signed-off-by: Himanshu Jha
Signed-off-by: Julia Lawall
---
v2
lso be removed in this same patch:
* Licensed under the GPL-2 or later.
And lastly, MODULE_LICENSE() should also be checked, which appear
to be correct in its current form.
> /*
> * ADIS16203 Programmable 360 Degrees Inclinometer
> *
> --
> 2.1.4
>
--
Hima
On Sat, Mar 16, 2019 at 01:00:39PM +, Mike Looijmans wrote:
> On 16-03-19 11:24, Himanshu Jha wrote:
> > On Wed, Mar 06, 2019 at 08:31:48AM +0100, Mike Looijmans wrote:
> >> The SPI interface implementation was completely broken.
> >>
> >> When using the SPI
o work before:
root@beaglebone:/sys/bus/iio/devices/iio:device1# cat name in_temp_input \
in_pressure_input in_humidityrelative_input in_resistance_input
bme680
26860 --> w/o your patch it used to be 26.86000 degC
990.87000
55.26500
10091
I'm still assuming that there is some problem on my side, as it works
flawless for you. But it is really difficult for me to figure out
exactly where the problem could be!
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
> + u8 addr = *(const u8 *)reg;
> + u8 addr7;
Unused variable.
> + ret = bme680_regmap_spi_select_page(ctx, addr);
> + if (ret)
> + return ret;
>
> - return spi_write_then_read(spi, reg, reg_size, val, val_size);
> + addr |= 0x80; /* bit7 = RW = '1' */
> +
> + return spi_write_then_read(spi, &addr, 1, val, val_size);
> }
>
> static struct regmap_bus bme680_regmap_bus = {
> @@ -45,8 +111,8 @@ static int bme680_regmap_spi_read(void *context, const
> void *reg,
> static int bme680_spi_probe(struct spi_device *spi)
> {
> const struct spi_device_id *id = spi_get_device_id(spi);
> + struct bme680_spi_bus_context *bus_context;
> struct regmap *regmap;
> - unsigned int val;
> int ret;
>
> spi->bits_per_word = 8;
> @@ -56,45 +122,21 @@ static int bme680_spi_probe(struct spi_device *spi)
> return ret;
> }
>
> + bus_context = devm_kzalloc(&spi->dev, sizeof(*bus_context), GFP_KERNEL);
> + if (!bus_context)
> + return -ENOMEM;
> +
> + bus_context->spi = spi;
> + bus_context->current_page = 0xff; /* Undefined on warm boot */
OK. This is what you observed.
If this patch works as expected then I think a "Fixes:" tag should be
added while marking it for stable ?
Thanks for the patch Mike and apologies again for the whole mess.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
;buffer_list);
> > + } else {
> > + return NULL;
>
> I'd argue that this is a bit redundant, because `dev` is NULL, the
> return below (return dev) will also return NULL.
+1
Also, subject title is incorrect.
Always use:
$ git log --oneline drivers/
On Mon, Jan 14, 2019 at 03:19:13PM -0500, Sebastien Bourdelin wrote:
> This commit allow the driver to work with device-tree.
>
> Signed-off-by: Sebastien Bourdelin
> ---
Acked-by: Himanshu Jha
Thanks!
> v2 -> v3:
> - remove of_match_ptr: Suggested by Jonathan
On Mon, Jan 14, 2019 at 03:19:14PM -0500, Sebastien Bourdelin wrote:
> BME680 is a pressure/temperature/humidity/voc sensor.
>
> Signed-off-by: Sebastien Bourdelin
> ---
> v2 -> v3:
> - change i2c address to 0x76 as it seems more reliable: Suggested by
> Himanshu Jha
Hi Sebastien,
On Mon, Jan 14, 2019 at 03:00:41PM -0500, sebastien bourdelin wrote:
> Hi,
>
> On 1/12/19 4:42 AM, Himanshu Jha wrote:
> > On Fri, Jan 11, 2019 at 03:53:58PM -0500, Sebastien Bourdelin wrote:
> > > This commit allow the driver to work with device-tree.
&g
ed this while testing.
Actallly, I don't understand what "VDIDO" is, as explained in the
datasheet.
Anyway, if the above compilation issue is not a problem, then
Acked-by: Himanshu Jha
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
On Wed, Jan 02, 2019 at 01:25:27PM -0800, Matt Ranostay wrote:
>
> > On Dec 24, 2018, at 01:58, Himanshu Jha wrote:
> >
> >> On Fri, Dec 21, 2018 at 03:26:26PM -0800, Amir Mahdi Ghorbanian wrote:
> >> Replaced bool in struct with unsigned int bitfield to con
;
> + unsigned intchop_en : 1;
> + unsigned intbuf_en : 1;
> + unsigned intunipolar_en : 1;
> + unsigned intburnout_curr_en : 1;
> };
>
> #endif /* IIO_ADC_AD7192_H_ */
> --
> 2.7.4
>
Goodluck!
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
oe - I find this tag kinda useless and duplicative. But whatever.
I'm fine either way, just the problem is:
Co-developed-by Vs Co-Developed-by
with checkpatch spitting out that it is not a valid signature.
In the end, I can completely remove the tag from docs if it is useless
and duplicati
On Fri, Dec 14, 2018 at 09:39:10AM -0800, Joe Perches wrote:
> On Fri, 2018-12-14 at 22:58 +0530, Himanshu Jha wrote:
> > On Fri, Dec 14, 2018 at 08:27:33AM -0800, Joe Perches wrote:
> > > Is it really important to specify things like 75% / 25%
> > > authorship credi
nother
> developer
> along with the original author. This is useful at times when multiple people
> work on a single patch. Note, this person also needs to have a
> Signed-off-by:
> line in the patch as well.
> --
> 2.7.4
>
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
On Fri, Dec 14, 2018 at 08:27:33AM -0800, Joe Perches wrote:
> On Fri, 2018-12-14 at 21:46 +0530, Himanshu Jha wrote:
> > On Fri, Dec 14, 2018 at 07:52:15AM -0800, Joe Perches wrote:
> > > On Fri, 2018-12-14 at 14:01 +0100, Jorge Ramirez-Ortiz wrote:
> > > > As per Do
does multiple Signed-off-by: in the commits imply that
the patch was created by all those developers ?
I don't think so, perhaps this was the reason to introduce
Co-developed-by: tag.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
.lip6.fr
> https://systeme.lip6.fr/mailman/listinfo/cocci
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
> Signed-off-by: Marcelo Schmitt
> Signed-off-by: Gabriel Capella
> ---
Use `./scripts/get_maintainer.pl ` to list the DT
maintainers and the relevant mailing list.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
o_cmd(state, SPS30_START_MEAS, NULL, 0);
> + if (ret) {
> + dev_err(&client->dev, "failed to start measurement\n");
> + return ret;
> + }
> +
> + ret = devm_iio_triggered_buffer_setup(&client->dev, indio_dev, NULL,
> + sps30_trigger_handler, NULL);
> + if (ret)
> + return ret;
> +
> + return devm_iio_device_register(&client->dev, indio_dev);
> +}
> +
> +static int sps30_remove(struct i2c_client *client)
Perfect candidate for `devm_add_action_or_reset()` ?
> +{
> + struct iio_dev *indio_dev = i2c_get_clientdata(client);
> + struct sps30_state *state = iio_priv(indio_dev);
> +
> + sps30_do_cmd(state, SPS30_STOP_MEAS, NULL, 0);
> +
> + return 0;
> +}
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
tree/bindings/iio/resolver/ad2s1210.txt
Cc'ed to devictree list + Rob(DT Maintainer).
Just wondering why didn't it came up till now from the IIO reviewers ? v7!!
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
aranteed to be -1..0
Regardless, integer conversion rules will kick in.
> But the :1 adds instructions, so at least for only one bool, where little
> space is saved, it is probably not worth it.
True, we should reply on a promised guideline rather than possibility.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
ble alignement issues" in CHECK report is difficult to figure
out by just doing a glance analysis. :)
Linus also suggested to use bool as the base type i.e., `bool x:1` but
again sizeof(_Bool) is implementation defined ranging from 1-4 bytes.
And since this issue is added to checkpatch now, very
BME0280", BME280_CHIP_ID },
Therefore, I used BME0680 for bosch bme680 sensor!
In OF matching, we use vendor prefixes and that looks more legimate:
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/tree/Documentation/devicetree/bindings/vendor-prefixes.txt
Dan,
These questions are not just for you but to rest of the community
members as well.
If there is something I misunderstood, then please let me know :)
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
I missing something?
Your patch applies fine.
I think the problem is on Lars end due to Thunderbird.
In the meantime, you can verify the patch using:
$ git am
Also, you can try to use `git send-email` to send patches.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
se three breaks are not proper aligned.
Please send the new version of a patch as a *new* thread and don't
use `--in-reply-to` flag(if you're using) to chain into older versions
as whole thread of older discussion comes up and is often not required.
The changelog gives enough info of what's new in the revised series.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
-email`.
Also, as a safety measure you may use the `--dry-run` flag
of `git send-email` to see how it would look like when you
send the patch.
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
ap = devm_regmap_init_spi(spi, &rm3100_regmap_config);
> + if (IS_ERR(regmap))
> + return PTR_ERR(regmap);
> +
> + return rm3100_common_probe(&spi->dev, regmap, spi->irq);
> +}
> +
> +static const struct of_device_id rm3100_dt_match[] = {
ertainly it is undefined behavior and called "overflow".
And here `temp` is guaranteed to not overflow!
But I don't understand what issue are you trying to resolve here and I'm
interested in this particular set of warnings because I too get coverity
scan reports on the same alth
216 For 'GNU General Public License (GPL) version 2 only' use:
217 SPDX-License-Identifier: GPL-2.0
218 For 'GNU General Public License (GPL) version 2 or any later
version' use:
219 SPDX-License-Identifier: GPL-2.0+
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
6.GA2077@himanshu-Vostro-3559/
And it nests properly in the given thread avoiding any noise to kbuild
bot.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
gnetometer/hmc5843_i2c.ko]
> >> undefined!
You would need to export these above symbols using EXPORT_SYMBOL()
to be used by i2c/spi modules.
But on the other hand, exporting too many symbols is a bad idea since
it is only used for this driver and not at any other place in IIO.
So,
er
//# of_device_get_match_data() returns const * and therefore the left
//# argument of assignment should also be a const * for compatible
//# types.
///
// Confidence: Moderate
// Copyright: (C) 2018 Himanshu Jha, GPLv2.
// Copyright: (C) 2018 Julia Lawall, INRIA/LIP6. GPLv
o "Keyser Söze" once you're done with your major
at University. You would need to test/review patches in future.
Not a big deal though..
> +
> +static const struct of_device_id st_vl53l0x_dt_match[] = {
> + { .compatible = "st,vl53l0x-i2c", },
> + {
of the drivers ?
I see its wide usage in IIO without bug reports:
himanshu@himanshu-Vostro-3559:~/linux-next$ git grep -w "IIO_DEGREE_TO_RAD"
drivers/iio/ | wc -l
34
And that concludes, that there is some problem within your code!
In the meantime, you can try to look the disassemb
ur queries doesn't get included in the commit
message.
And no need to reply an explicit "thanks".
That is implicit ;)
We already have a ~30k email traffic on LKML...
https://marc.info/?l=linux-kernel&r=1&w=2
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
nd would save
his effort of doing it again :)
https://lore.kernel.org/lkml/20180903183618.ga6...@embeddedor.com/
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Xilinx, Inc.");
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
tries--);
> + if (!tries)
> + return -ETIMEDOUT;
> +
> + msg[0].addr = client->addr;
> + msg[0].buf = &write_command;
> + msg[0].len = 1;
> + msg[0].flags = client->flags | I2C_M_STOP;
> +
> + msg[1].addr = client->addr;
>
* 314159ULL + 900ULL) / 1800ULL)
This '/' operator might be the culprit!
Just for checking that the error, remove the macro declaration
`FXAS21002C_SCALE`
plus its usage and re-cross compile using `make ARCH=i386`.
In my case I used the `div64_s64` function handles builds fo
; + int ret;
> +
> + indio_dev = devm_iio_device_alloc(&client->dev, sizeof(*data));
> + if (!indio_dev)
> + return -ENOMEM;
> +
> + data = iio_priv(indio_dev);
> + data->client = client;
> + data->indio_dev = indio_dev;
Is this required ?
> + i2c_set_clientdata(client, indio_dev);
> +
> + if (!i2c_check_functionality(client->adapter,
> + I2C_FUNC_SMBUS_BYTE_DATA | I2C_FUNC_I2C))
> + return -EOPNOTSUPP;
> +
> + indio_dev->dev.parent = &client->dev;
> + indio_dev->name = VL53L0X_DRV_NAME;
> + indio_dev->info = &vl53l0x_info;
> + indio_dev->channels = vl53l0x_channels;
> + indio_dev->num_channels = ARRAY_SIZE(vl53l0x_channels);
> + indio_dev->modes = INDIO_DIRECT_MODE;
> +
> + ret = devm_iio_device_register(&client->dev, indio_dev);
return devm_iio_device_register(&client->dev, indio_dev);
> + if (ret)
> + return ret;
> +
> + return 0;
> +}
Do you have the sensor and are these patches tested ?
Just curious!
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
On Tue, Sep 11, 2018 at 02:46:38PM +0800, Song Qiang wrote:
> On Mon, Sep 10, 2018 at 11:27:47PM +0530, Himanshu Jha wrote:
> > On Mon, Sep 10, 2018 at 10:42:59PM +0800, Song Qiang wrote:
> > > This driver was originally written by ST in 2016 as a misc input device,
>
)
> + return -ENOMEM;
> +
> + data = iio_priv(indio_dev);
> + data->client = client;
> + i2c_set_clientdata(client, indio_dev);
> + mutex_init(&data->lock);
> +
> + if (!i2c_check_functionality(client->adapter, I2C_FUNC_SMBUS_BYTE
sensor_data.hum_data);
> + data->buffer[i] = sensor_data.temp_data;
No, this seems wrong!
We have buffer support to either take both readings(temp & humid)
simultaneously, or only single channel using specified scan mask.
Patch title should be:
"
> + __be16 bulk_raw;
> +
> + switch (chan->type) {
> + case IIO_ANGL_VEL:
> + ret = regmap_bulk_read(data->regmap, chan->address,
> +&bulk_raw, sizeof(bulk_raw));
> + if (ret)
> + return ret;
> +
> + *val = sign_extend32(be16_to_cpu(bulk_raw), 15);
> + return IIO_VAL_INT;
> + case IIO_TEMP:
> + ret = regmap_read(data->regmap, chan->address, val);
> + if (ret)
> + return ret;
> +
> + return IIO_VAL_INT;
> + default:
> + return -EINVAL;
> + }
> +}
> +
> +static int fxas21002c_read_raw(struct iio_dev *indio_dev,
> +struct iio_chan_spec const *chan, int *val,
> +int *val2, long mask)
Similarly here.
static int fxas21002c_read_raw(struct iio_dev *indio_dev,
struct iio_chan_spec const *chan, int *val,
int *val2, long mask)
Thanks
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
On Sun, Aug 19, 2018 at 05:25:14PM +0100, Jonathan Cameron wrote:
> On Sat, 11 Aug 2018 15:56:36 +0530
> Himanshu Jha wrote:
>
> > val2 is responsible for the floating part of the number to be
> > written to the device. We don't need the floating part
> > while wr
On Sat, Aug 18, 2018 at 10:10:26PM +0800, zhong jiang wrote:
> On 2018/8/18 22:01, Julia Lawall wrote:
> >
> > On Sat, 18 Aug 2018, zhong jiang wrote:
> >
> >> On 2018/8/18 20:52, Himanshu Jha wrote:
> >>> On Sat, Aug 18, 2018 at 08:01:40P
ot; -> "detect"
Otherwise,
Acked-by: Himanshu Jha
Thanks for cleaning up, we still have few more *_alloc/memset
in the mainline, especially in the scsi subsystem, even after
I cleaned up with two long patch series in the past.
--
Himanshu Jha
Undergraduate Student
Department of Electr
ps://www.kernel.org/doc/html/latest/process/submitting-patches.html#the-canonical-patch-format
Hope that helps!
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
ff-by: Himanshu Jha
---
drivers/iio/chemical/bme680_core.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/iio/chemical/bme680_core.c
b/drivers/iio/chemical/bme680_core.c
index 7d9bb62baa3f..9d5a05e054d1 100644
--- a/drivers/iio/chemical/bme680_core.c
+++ b/drivers/iio/chemical/bme680_c
es are
obsolete and likely more prone to be disfunctional.
For instance: https://systeme.lip6.fr/pipermail/cocci/2017-December/004799.html
Thanks.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
On Fri, Aug 03, 2018 at 12:55:51PM +0100, Colin King wrote:
> From: Colin Ian King
>
> fix spelling mistake in dev_err error message text
>
> Signed-off-by: Colin Ian King
Oops! Thanks for the patch Colin.
Reviewed-by: Himanshu Jha
--
Himanshu Jha
Undergraduate Studen
dia/_tech/media/datasheets/BST-BME680-DS001-00.pdf
Cc: Daniel Baluta
Signed-off-by: Himanshu Jha
---
v5:
-removed unnecessary casts from compensate functions.
-used devm_iio_register for now.
-used bitshifting near approximation instead of complex multiplication
in bme680
On Mon, Jul 23, 2018 at 03:16:10PM -0700, David Frey wrote:
> On 7/22/2018 3:21 PM, Himanshu Jha wrote:
> >On Sat, Jul 21, 2018 at 08:45:34PM +0300, Daniel Baluta wrote:
> >>On Sat, Jul 21, 2018 at 6:43 PM, Andy Shevchenko
> >> wrote:
> >>>On Sat, Jul 21, 20
On Sat, Jul 21, 2018 at 08:45:34PM +0300, Daniel Baluta wrote:
> On Sat, Jul 21, 2018 at 6:43 PM, Andy Shevchenko
> wrote:
> > On Sat, Jul 21, 2018 at 6:36 PM, Himanshu Jha
> > wrote:
> >
> >>> > + /* Look up table 1 for the possible gas range va
On Sat, Jul 21, 2018 at 06:43:51PM +0300, Andy Shevchenko wrote:
> On Sat, Jul 21, 2018 at 6:36 PM, Himanshu Jha
> wrote:
>
> >> > + /* Look up table 1 for the possible gas range values */
> >> > + u32 lookupTable1[16] = {2147
>
> Don't think you can get here so this code should not be here.
Ok.
> > + default:
> > + return -EINVAL;
> > + }
> > + default:
> > + return -EINVAL;
> > + }
> > +
>
> You can't
dia/_tech/media/datasheets/BST-BME680-DS001-00.pdf
Cc: Daniel Baluta
Signed-off-by: Himanshu Jha
---
v4:
-Added Bosch API links and datasheet link.
-explained with comments about the compensate functions.
-fixed SPI ID register address.
-Used FIELD_PREP macro to avoid unnecess
Hi Jonathan,
On Sun, Jul 15, 2018 at 10:10:36AM +0100, Jonathan Cameron wrote:
> On Sat, 14 Jul 2018 13:03:42 +0530
> Himanshu Jha wrote:
>
> > Hi David,
> >
> > On Fri, Jul 13, 2018 at 01:42:35PM -0700, David Frey wrote:
> > > Hi Himanshu Jha,
> >
Hi David,
On Fri, Jul 13, 2018 at 01:42:35PM -0700, David Frey wrote:
> Hi Himanshu Jha,
>
> First a bit of background. I'm working on a device which will contain a
> bme680 sensor. A colleague of mine started work on a Linux kernel driver
> for the chip a little while ag
dia/_tech/media/datasheets/BST-BME680-DS001-00.pdf
Cc: Daniel Baluta
Signed-off-by: Himanshu Jha
---
v3:
-moved files to chemical directory instead of a dedicated directory.
-read calibration parameters serially with endian conversions.
-drop some return ret.
-removed few unnecessa
_core_probe);
>
> +int inv_mpu_core_remove(struct inv_mpu6050_state *st)
> +{
> + return regulator_disable(st->vddio_supply);
> +}
EXPORT_SYMBOL_GPL(inv_mpu_core_remove); ?
This is causing 0-day test build failure perhaps.
--
Himanshu Jha
Undergraduate Student
Department of Electronics &
On Sat, Jul 07, 2018 at 07:01:55PM +0100, Jonathan Cameron wrote:
> On Fri, 6 Jul 2018 13:20:16 +0530
> Himanshu Jha wrote:
>
> > Bosch BME680 is a 4-in-1 sensor with temperature, pressure, humidity
> > and gas sensing capability. It supports both I2C and SPI communica
dia/_tech/media/datasheets/BST-BME680-DS001-00.pdf
Cc: Daniel Baluta
Signed-off-by: Himanshu Jha
---
v2:
-Used devm_add_action() to add a generic remove method for
both I2C & SPI driver.
-Introduction of compensation functions.
-chip initialisation routines
On Fri, Jun 29, 2018 at 03:18:18AM +0530, Himanshu Jha wrote:
> On Thu, Jun 28, 2018 at 03:13:32PM +0300, Stefan Popa wrote:
> > The AD5758 is a single channel DAC with 16-bit precision which uses the
> > SPI interface that operates at clock rates up to 50MHz.
> >
> > T
gt; + ARRAY_SIZE(ad5758_dc_dc_ilim),
> + sizeof(int), cmpfunc);
Thanks.
--
Himanshu Jha
Undergraduate Student
Department of Electronics & Communication
Guru Tegh Bahadur Institute of Technology
Move adis16201 driver out of staging and merge into mainline
IIO subsystem.
Signed-off-by: Himanshu Jha
---
drivers/iio/accel/Kconfig | 12 ++
drivers/iio/accel/Makefile| 1 +
drivers/iio/accel/adis16201.c | 321 ++
drivers
Use GENMASK to improve readability and remove the local variables used to
store intermediate data.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 34 +++---
1 file changed, 15 insertions(+), 19 deletions(-)
diff --git a/drivers/staging/iio
Remove few unused headers files since the adis core handles the buffer and
sysfs support.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b/drivers/staging/iio/accel/adis16201.c
Split the line over 80 characters limit to fix checkpatch
warning.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b/drivers/staging/iio/accel/adis16201.c
index
s",
> + .pm = &ams_pm_ops,
> + .of_match_table = ams_of_match_table,
> + },
> +};
> +module_platform_driver(ams_driver);
--
Thanks
Himanshu Jha
Remove few unnecessary comments since the macro definitions clearly
justify their purpose.
Signed-off-by: Himanshu Jha
---
v2:
-reodered patch series.
drivers/staging/iio/accel/adis16201.c | 36 ---
1 file changed, 36 deletions(-)
diff --git a/drivers
Add a _REG suffix to distinguish between registers and the register bit
fileds.
Signed-off-by: Himanshu Jha
---
v2:
-reordered patch series.
drivers/staging/iio/accel/adis16201.c | 84 +--
1 file changed, 42 insertions(+), 42 deletions(-)
diff --git a
Use sign_extned32() for 32 bit sign extending rather than hard coding.
Signed-off-by: Himanshu Jha
---
v2:
-no change in this patch.
drivers/staging/iio/accel/adis16201.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b
Clarify the conversion and formation of resultant data in the
adis16201_read_raw() with sufficient comments and remove the unnecessary
comments.
Signed-off-by: Himanshu Jha
---
v2:
-clarify voltage base conversions.
drivers/staging/iio/accel/adis16201.c | 27 ++-
1
In adis16201_read_raw() adjust an argument to match an open parentheses
using tabs and spaces.
Signed-off-by: Himanshu Jha
---
v2:
-aligned perfectly to match open parentheses.
drivers/staging/iio/accel/adis16201.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers
Prefer reverse christmas tree ordering of declarations to improve
readability.
Signed-off-by: Himanshu Jha
---
v2:
-no change in this patch.
drivers/staging/iio/accel/adis16201.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b
Group register definitions with its register field bits to improve
readability and easy identification. A small comment is also added to
denote the purpose/functionality of the grouped register definitions.
Signed-off-by: Himanshu Jha
---
v2:
-reordered patch series.
drivers/staging/iio
Move the adis16201 driver out of staging directory and merge to the
mainline IIO subsystem.
Signed-off-by: Himanshu Jha
---
v2:
-no change in this patch.
drivers/iio/accel/Kconfig | 12 ++
drivers/iio/accel/Makefile| 1 +
drivers/iio/accel/adis16201.c
: Himanshu Jha
---
v2:
-explained every change in the process of renaming macros.
drivers/staging/iio/accel/adis16201.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b/drivers/staging/iio/accel/adis16201.c
index 0fae8aa
to
suggest more cleanups/fix while pointing inline to the patch, the
necessary changes. The framing of patch is made consistent with the
datasheet naming where possible.
For all the patches:
Suggested-by: Jonathan Cameron
https://marc.info/?l=linux-iio&m=151775804702998&w=2
Himanshu Jha (
On Tue, Mar 13, 2018 at 11:31:19AM -0500, Gustavo A. R. Silva wrote:
>
>
> On 03/13/2018 11:24 AM, Himanshu Jha wrote:
> >Hi Gustavo,
> >
> >On Tue, Mar 13, 2018 at 10:23:43AM -0500, Gustavo A. R. Silva wrote:
> >>In preparation to enabling -Wvla, remove
#x27;ed you and Kees to avoid the patch collisions.
--
Thanks
Himanshu Jha
o-3559:~/linux-next$ git log --oneline
drivers/net/wireless/ath/ath9k/dfs.c
626ab67 ath9k: dfs: use swap macro in ath9k_check_chirping
50c8cd4 ath9k: remove cast to void pointer
8fc2b61 ath9k: DFS - add pulse chirp detection for FCC
--
Thanks
Himanshu Jha
On Thu, Mar 08, 2018 at 11:39:15AM -0800, Kees Cook wrote:
> On Thu, Mar 8, 2018 at 10:45 AM, Himanshu Jha
> wrote:
> > In preparation to enabling -Wvla, remove VLA usage and replace it
> > with fixed a fixed length array and therefore, prevent potential
> > stack overflo
AG_STAT_ALARM1 BIT(8)
> +#define ADIS16209_DIAG_STAT_SELFTEST_FAIL_BIT 5
> +#define ADIS16209_DIAG_STAT_SPI_FAIL_BIT3
> +#define ADIS16209_DIAG_STAT_FLASH_UPT_BIT 2
#define ADIS16209_STAT_FLASH_UPT_FAIL_BIT2
?
It represents flash update fail bit!
--
Thanks
Himanshu Jha
-by: Himanshu Jha
---
drivers/iio/potentiometer/ds1803.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/iio/potentiometer/ds1803.c
b/drivers/iio/potentiometer/ds1803.c
index 9b0ff4a..6bf12c9 100644
--- a/drivers/iio/potentiometer/ds1803.c
+++ b/drivers/iio
On Wed, Mar 07, 2018 at 08:50:30PM +, Jonathan Cameron wrote:
> On Mon, 5 Mar 2018 13:19:29 +0530
> Himanshu Jha wrote:
>
> > Clarify the conversion and formation of resultant data in the
> > adis16201_read_raw() with sufficient comments.
> >
> > Signed-off
Use kasprintf instead of combination of kmalloc and sprintf and
therefore avoid unnecessary computation of string length.
Also, remove the useless local variable.
Signed-off-by: Himanshu Jha
---
drivers/usb/isp1760/isp1760-udc.c | 6 +-
1 file changed, 1 insertion(+), 5 deletions(-)
v2
On Wed, Mar 07, 2018 at 08:20:54PM +0200, Andy Shevchenko wrote:
> On Wed, Mar 7, 2018 at 8:08 PM, Himanshu Jha
> wrote:
> > Use kasprintf instead of combination of kmalloc and sprintf and
> > therefore avoid unnecessary computation of string length.
>
> >
Use kasprintf instead of combination of kmalloc and sprintf and
therefore avoid unnecessary computation of string length.
Signed-off-by: Himanshu Jha
---
drivers/usb/isp1760/isp1760-udc.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/usb/isp1760/isp1760-udc.c
b
Use kasprintf instead of combination of kmalloc and sprintf.
Signed-off-by: Himanshu Jha
---
drivers/mfd/ab8500-debugfs.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/mfd/ab8500-debugfs.c b/drivers/mfd/ab8500-debugfs.c
index 8ba4107..831a1ce 100644
--- a/drivers
Use kasprintf instead of combination of kmalloc and sprintf. Also,
remove the local variables used for storing the string length as they
are not required now.
Signed-off-by: Himanshu Jha
---
drivers/gpu/drm/vmwgfx/vmwgfx_msg.c | 13 +++--
1 file changed, 3 insertions(+), 10 deletions
such as
Fatory Reset, Software Reset, etc.
See, it is difficult to point the perfect names than the suitable ones!
And let's just leave these *bikeshedding* ;-)
--
Thanks
Himanshu Jha
Remove unnecessary comments since the definitions are pretty clear
with their macro names.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 82 +--
1 file changed, 10 insertions(+), 72 deletions(-)
diff --git a/drivers/staging/iio/accel
Prefer reverse christmas tree ordering of declarations to improve
readability.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b/drivers/staging/iio/accel
Use switch statement instead of if-else pair to explicitly match
the only two channels present.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/iio/accel/adis16201.c
b/drivers
Clarify the conversion and formation of resultant data in the
adis16201_read_raw() with sufficient comments.
Signed-off-by: Himanshu Jha
---
drivers/staging/iio/accel/adis16201.c | 10 ++
1 file changed, 10 insertions(+)
diff --git a/drivers/staging/iio/accel/adis16201.c
b/drivers
Move the adis16201 driver out of staging directory and merge to the
mainline IIO subsystem.
Signed-off-by: Himanshu Jha
---
drivers/iio/accel/Kconfig | 12 ++
drivers/iio/accel/Makefile| 1 +
drivers/iio/accel/adis16201.c | 323
1 - 100 of 254 matches
Mail list logo