diff for duplicates of <562A65D3.8090306@roeck-us.net> diff --git a/a/1.txt b/N1/1.txt index 696387a..5f13e74 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -55,7 +55,7 @@ I'll need some time to go through the patch in detail Some quick comments below. > > /* settings - depend on use case */ > #define INA219_CONFIG_DEFAULT 0x399F /* PGA=8 */ -> #define INA226_CONFIG_DEFAULT 0x4527 /* averages\x16 */ +> #define INA226_CONFIG_DEFAULT 0x4527 /* averages=16 */ > > /* worst case is 68.10 ms (~14.6Hz, ina219) */ > -#define INA2XX_CONVERSION_RATE 15 @@ -246,7 +246,7 @@ can determine if there is an error by checking if the returned value is < 0. > * the chip has been reset let's check the calibration > * register and reinitialize if needed. > */ -> - if (data->regs[INA2XX_CALIBRATION] = 0) { +> - if (data->regs[INA2XX_CALIBRATION] == 0) { > - dev_warn(dev, "chip not calibrated, reinitializing\n"); > - > - rv = ina2xx_init(data); @@ -448,7 +448,7 @@ are read. I don't immediately see if and how this is beneficial. > return count; > } > @@ -370,65 +333,58 @@ static ssize_t ina226_set_interval(struct device *dev, -> if (val > INT_MAX || val = 0) +> if (val > INT_MAX || val == 0) > return -EINVAL; > > - mutex_lock(&data->update_lock); @@ -612,7 +612,7 @@ Please no unnecessary changes. > + /* Check for shunt resistor value. > + * Give precedence to device tree over must-recompile. > */ -> - if (data->kind = ina226) +> - if (data->kind == ina226) > - ina226_set_update_interval(data); > - else > - data->update_interval = HZ / INA2XX_CONVERSION_RATE; @@ -661,8 +661,8 @@ personal preference, and I don't see the improvement. Seems to be obvious to me. > data->groups[group++] = &ina2xx_group; -> - if (data->kind = ina226) -> + if (ina226 = id->driver_data) +> - if (data->kind == ina226) +> + if (ina226 == id->driver_data) Not likely to accept Yoda programming I am. @@ -688,9 +688,3 @@ If not, please no unnecessary whitespace changes. > MODULE_DESCRIPTION("ina2xx driver"); > MODULE_LICENSE("GPL"); > - - -_______________________________________________ -lm-sensors mailing list -lm-sensors@lm-sensors.org -http://lists.lm-sensors.org/mailman/listinfo/lm-sensors diff --git a/a/content_digest b/N1/content_digest index 50a9f56..5968b52 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,8 +1,8 @@ "ref\056263973.300@roeck-us.net\0" "ref\01445616800-21329-1-git-send-email-mtitinger@baylibre.com\0" "From\0Guenter Roeck <linux@roeck-us.net>\0" - "Subject\0Re: [lm-sensors] [RFC] hwmon: ina2xx: port to using remap, improve bandwidth.\0" - "Date\0Fri, 23 Oct 2015 16:52:35 +0000\0" + "Subject\0Re: [RFC] hwmon: ina2xx: port to using remap, improve bandwidth.\0" + "Date\0Fri, 23 Oct 2015 09:52:35 -0700\0" "To\0Marc Titinger <mtitinger@baylibre.com>" " jdelvare@suse.com\0" "Cc\0lm-sensors@lm-sensors.org" @@ -68,7 +68,7 @@ ">\n" "> /* settings - depend on use case */\n" "> #define INA219_CONFIG_DEFAULT\t\t0x399F\t/* PGA=8 */\n" - "> #define INA226_CONFIG_DEFAULT\t\t0x4527\t/* averages\026 */\n" + "> #define INA226_CONFIG_DEFAULT\t\t0x4527\t/* averages=16 */\n" ">\n" "> /* worst case is 68.10 ms (~14.6Hz, ina219) */\n" "> -#define INA2XX_CONVERSION_RATE\t\t15\n" @@ -259,7 +259,7 @@ "> \t\t * the chip has been reset let's check the calibration\n" "> \t\t * register and reinitialize if needed.\n" "> \t\t */\n" - "> -\t\tif (data->regs[INA2XX_CALIBRATION] = 0) {\n" + "> -\t\tif (data->regs[INA2XX_CALIBRATION] == 0) {\n" "> -\t\t\tdev_warn(dev, \"chip not calibrated, reinitializing\\n\");\n" "> -\n" "> -\t\t\trv = ina2xx_init(data);\n" @@ -461,7 +461,7 @@ "> \treturn count;\n" "> }\n" "> @@ -370,65 +333,58 @@ static ssize_t ina226_set_interval(struct device *dev,\n" - "> \tif (val > INT_MAX || val = 0)\n" + "> \tif (val > INT_MAX || val == 0)\n" "> \t\treturn -EINVAL;\n" ">\n" "> -\tmutex_lock(&data->update_lock);\n" @@ -625,7 +625,7 @@ "> +\t/* Check for shunt resistor value.\n" "> +\t * Give precedence to device tree over must-recompile.\n" "> \t */\n" - "> -\tif (data->kind = ina226)\n" + "> -\tif (data->kind == ina226)\n" "> -\t\tina226_set_update_interval(data);\n" "> -\telse\n" "> -\t\tdata->update_interval = HZ / INA2XX_CONVERSION_RATE;\n" @@ -674,8 +674,8 @@ "Seems to be obvious to me.\n" "\n" "> \tdata->groups[group++] = &ina2xx_group;\n" - "> -\tif (data->kind = ina226)\n" - "> +\tif (ina226 = id->driver_data)\n" + "> -\tif (data->kind == ina226)\n" + "> +\tif (ina226 == id->driver_data)\n" "\n" "Not likely to accept Yoda programming I am.\n" "\n" @@ -700,12 +700,6 @@ "> MODULE_AUTHOR(\"Lothar Felten <l-felten@ti.com>\");\n" "> MODULE_DESCRIPTION(\"ina2xx driver\");\n" "> MODULE_LICENSE(\"GPL\");\n" - ">\n" - "\n" - "\n" - "_______________________________________________\n" - "lm-sensors mailing list\n" - "lm-sensors@lm-sensors.org\n" - http://lists.lm-sensors.org/mailman/listinfo/lm-sensors + > -f3a3e7ed99720f3de9f0018580e0a631027c9db1f6f6de691e51b40bbdb1e9c5 +6e34aeecb87d3ab65ca7e50506b9b6e3ae5180231532d8ac0b3a70b8edeed63d
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.