All of lore.kernel.org
 help / color / mirror / Atom feed
diff for duplicates of <4933F366.7010205@cam.ac.uk>

diff --git a/a/1.txt b/N1/1.txt
index b1aec23..e4595a4 100644
--- a/a/1.txt
+++ b/N1/1.txt
@@ -113,9 +113,9 @@ index 0000000..88ad39d
 +	struct iio_dev *indio_dev = dev_get_drvdata(dev);
 +	struct iio_scan_el *this_el = to_iio_scan_el(attr);
 +
-+	state = !(buf[0] == '0');
++	state = !(buf[0] = '0');
 +	mutex_lock(&indio_dev->mlock);
-+	if (indio_dev->currentmode == INDIO_RING_TRIGGERED) {
++	if (indio_dev->currentmode = INDIO_RING_TRIGGERED) {
 +		ret = -EBUSY;
 +		goto error_ret;
 +	}
@@ -154,9 +154,9 @@ index 0000000..88ad39d
 +	int ret = 0;
 +	struct iio_dev *indio_dev = dev_get_drvdata(dev);
 +	bool state;
-+	state = !(buf[0] == '0');
++	state = !(buf[0] = '0');
 +	mutex_lock(&indio_dev->mlock);
-+	if (indio_dev->currentmode == INDIO_RING_TRIGGERED) {
++	if (indio_dev->currentmode = INDIO_RING_TRIGGERED) {
 +		ret = -EBUSY;
 +		goto error_ret;
 +	}
@@ -195,11 +195,11 @@ index 0000000..88ad39d
 +
 +	/* Does anyone care? */
 +	if (test_bit(IIO_BUSY_BIT_POS, &ev_int->handler.flags)) {
-+		if (ev_int->current_events == ev_int->max_events)
++		if (ev_int->current_events = ev_int->max_events)
 +			return 0;
 +		ev = kmalloc(sizeof(struct iio_detected_event_list),
 +			     GFP_KERNEL);
-+		if (ev == NULL) {
++		if (ev = NULL) {
 +			ret = -ENOMEM;
 +			goto error_ret;
 +		}
@@ -276,9 +276,8 @@ index 0000000..88ad39d
 +{
 +	int ret;
 +
-+	dev_info->interrupts[line_number] =
-+		kmalloc(sizeof(struct iio_interrupt), GFP_KERNEL);
-+	if (dev_info->interrupts[line_number] == NULL) {
++	dev_info->interrupts[line_number] +		kmalloc(sizeof(struct iio_interrupt), GFP_KERNEL);
++	if (dev_info->interrupts[line_number] = NULL) {
 +		ret = -ENOMEM;
 +		goto error_ret;
 +	}
@@ -338,7 +337,7 @@ index 0000000..88ad39d
 +	unsigned long flags;
 +	/* take mutex to protect this element */
 +	mutex_lock(&el->exist_lock);
-+	if (el->refcount == 0) {
++	if (el->refcount = 0) {
 +		spin_lock_irqsave(&inter->ev_list_lock, flags);
 +		/*take spinlock*/
 +		list_add(&el->list, head);
@@ -358,7 +357,7 @@ index 0000000..88ad39d
 +	unsigned long flags;
 +	mutex_lock(&el->exist_lock);
 +	el->refcount--;
-+	if (el->refcount == 0) {
++	if (el->refcount = 0) {
 +		spin_lock_irqsave(&inter->ev_list_lock, flags);
 +		/* take spinlock */
 +		list_del_init(&el->list);
@@ -375,9 +374,9 @@ index 0000000..88ad39d
 +
 +	spin_lock(&iio_state_lock);
 +	for (id = 0; id <= 256; id++)
-+		if (iio_state.fhs[id] == NULL)
++		if (iio_state.fhs[id] = NULL)
 +			break;
-+	if (id == 256) {
++	if (id = 256) {
 +		spin_unlock(&iio_state_lock);
 +		return -ENOMEM;
 +	}
@@ -414,7 +413,7 @@ index 0000000..88ad39d
 +		return -ENODEV;
 +	}
 +	new_fops = fops_get(handler->fops);
-+	if (new_fops == NULL) {
++	if (new_fops = NULL) {
 +		fops_put(file->f_op);
 +		return -ENODEV;
 +	}
@@ -686,13 +685,13 @@ index 0000000..88ad39d
 +	int ret;
 +
 +idr_again:
-+	if (unlikely(idr_pre_get(&iio_idr, GFP_KERNEL) == 0))
++	if (unlikely(idr_pre_get(&iio_idr, GFP_KERNEL) = 0))
 +		return -ENOMEM;
 +
 +	spin_lock(&iio_idr_lock);
 +	ret = idr_get_new(&iio_idr, NULL, &dev_info->id);
 +	spin_unlock(&iio_idr_lock);
-+	if (unlikely(ret == -EAGAIN))
++	if (unlikely(ret = -EAGAIN))
 +		goto idr_again;
 +	else if (unlikely(ret))
 +		return ret;
@@ -765,14 +764,14 @@ index 0000000..88ad39d
 +{
 +	int ret = 0, i, j;
 +
-+	if (dev_info->num_interrupt_lines == 0)
++	if (dev_info->num_interrupt_lines = 0)
 +		return 0;
 +
 +	dev_info->event_interfaces = (struct iio_event_interface *)
 +		(kzalloc(sizeof(struct iio_event_interface)
 +			 *dev_info->num_interrupt_lines,
 +			 GFP_KERNEL));
-+	if (dev_info->event_interfaces == NULL) {
++	if (dev_info->event_interfaces = NULL) {
 +		ret = -ENOMEM;
 +		goto error_ret;
 +	}
@@ -785,7 +784,7 @@ index 0000000..88ad39d
 +		= kzalloc(sizeof(struct iio_interrupt *)
 +			  *dev_info->num_interrupt_lines,
 +			  GFP_KERNEL);
-+	if (dev_info->interrupts == NULL) {
++	if (dev_info->interrupts = NULL) {
 +		dev_err(dev_info->dev,
 +			"Failed to register sysfs hooks for events attributes");
 +		ret = -ENOMEM;
@@ -857,7 +856,7 @@ index 0000000..88ad39d
 +static void iio_device_unregister_eventset(struct iio_dev *dev_info)
 +{
 +	int i;
-+	if (dev_info->num_interrupt_lines == 0)
++	if (dev_info->num_interrupt_lines = 0)
 +		return;
 +	for (i = 0; i < dev_info->num_interrupt_lines; i++)
 +		sysfs_remove_group(&dev_info->sysfs_dev->kobj,
@@ -1939,3 +1938,8 @@ index 0000000..c79e2dd
 +#endif /* CONFIG_IIO_RING_BUFFER */
 +
 +#endif /* _IIO_RING_GENERIC_H_ */
+
+_______________________________________________
+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 08f1b15..e27652d 100644
--- a/a/content_digest
+++ b/N1/content_digest
@@ -1,6 +1,6 @@
  "ref\04933F291.4020001@cam.ac.uk\0"
  "From\0Jonathan Cameron <jic23@cam.ac.uk>\0"
- "Subject\0[Industrial I/O] [1/13] RFC: IIO core functionality\0"
+ "Subject\0[lm-sensors] [Industrial I/O] [1/13] RFC: IIO core functionality\0"
  "Date\0Mon, 01 Dec 2008 14:23:34 +0000\0"
  "To\0Jonathan Cameron <jic23@cam.ac.uk>\0"
  "Cc\0LKML <linux-kernel@vger.kernel.org>"
@@ -127,9 +127,9 @@
  "+\tstruct iio_dev *indio_dev = dev_get_drvdata(dev);\n"
  "+\tstruct iio_scan_el *this_el = to_iio_scan_el(attr);\n"
  "+\n"
- "+\tstate = !(buf[0] == '0');\n"
+ "+\tstate = !(buf[0] = '0');\n"
  "+\tmutex_lock(&indio_dev->mlock);\n"
- "+\tif (indio_dev->currentmode == INDIO_RING_TRIGGERED) {\n"
+ "+\tif (indio_dev->currentmode = INDIO_RING_TRIGGERED) {\n"
  "+\t\tret = -EBUSY;\n"
  "+\t\tgoto error_ret;\n"
  "+\t}\n"
@@ -168,9 +168,9 @@
  "+\tint ret = 0;\n"
  "+\tstruct iio_dev *indio_dev = dev_get_drvdata(dev);\n"
  "+\tbool state;\n"
- "+\tstate = !(buf[0] == '0');\n"
+ "+\tstate = !(buf[0] = '0');\n"
  "+\tmutex_lock(&indio_dev->mlock);\n"
- "+\tif (indio_dev->currentmode == INDIO_RING_TRIGGERED) {\n"
+ "+\tif (indio_dev->currentmode = INDIO_RING_TRIGGERED) {\n"
  "+\t\tret = -EBUSY;\n"
  "+\t\tgoto error_ret;\n"
  "+\t}\n"
@@ -209,11 +209,11 @@
  "+\n"
  "+\t/* Does anyone care? */\n"
  "+\tif (test_bit(IIO_BUSY_BIT_POS, &ev_int->handler.flags)) {\n"
- "+\t\tif (ev_int->current_events == ev_int->max_events)\n"
+ "+\t\tif (ev_int->current_events = ev_int->max_events)\n"
  "+\t\t\treturn 0;\n"
  "+\t\tev = kmalloc(sizeof(struct iio_detected_event_list),\n"
  "+\t\t\t     GFP_KERNEL);\n"
- "+\t\tif (ev == NULL) {\n"
+ "+\t\tif (ev = NULL) {\n"
  "+\t\t\tret = -ENOMEM;\n"
  "+\t\t\tgoto error_ret;\n"
  "+\t\t}\n"
@@ -290,9 +290,8 @@
  "+{\n"
  "+\tint ret;\n"
  "+\n"
- "+\tdev_info->interrupts[line_number] =\n"
- "+\t\tkmalloc(sizeof(struct iio_interrupt), GFP_KERNEL);\n"
- "+\tif (dev_info->interrupts[line_number] == NULL) {\n"
+ "+\tdev_info->interrupts[line_number] +\t\tkmalloc(sizeof(struct iio_interrupt), GFP_KERNEL);\n"
+ "+\tif (dev_info->interrupts[line_number] = NULL) {\n"
  "+\t\tret = -ENOMEM;\n"
  "+\t\tgoto error_ret;\n"
  "+\t}\n"
@@ -352,7 +351,7 @@
  "+\tunsigned long flags;\n"
  "+\t/* take mutex to protect this element */\n"
  "+\tmutex_lock(&el->exist_lock);\n"
- "+\tif (el->refcount == 0) {\n"
+ "+\tif (el->refcount = 0) {\n"
  "+\t\tspin_lock_irqsave(&inter->ev_list_lock, flags);\n"
  "+\t\t/*take spinlock*/\n"
  "+\t\tlist_add(&el->list, head);\n"
@@ -372,7 +371,7 @@
  "+\tunsigned long flags;\n"
  "+\tmutex_lock(&el->exist_lock);\n"
  "+\tel->refcount--;\n"
- "+\tif (el->refcount == 0) {\n"
+ "+\tif (el->refcount = 0) {\n"
  "+\t\tspin_lock_irqsave(&inter->ev_list_lock, flags);\n"
  "+\t\t/* take spinlock */\n"
  "+\t\tlist_del_init(&el->list);\n"
@@ -389,9 +388,9 @@
  "+\n"
  "+\tspin_lock(&iio_state_lock);\n"
  "+\tfor (id = 0; id <= 256; id++)\n"
- "+\t\tif (iio_state.fhs[id] == NULL)\n"
+ "+\t\tif (iio_state.fhs[id] = NULL)\n"
  "+\t\t\tbreak;\n"
- "+\tif (id == 256) {\n"
+ "+\tif (id = 256) {\n"
  "+\t\tspin_unlock(&iio_state_lock);\n"
  "+\t\treturn -ENOMEM;\n"
  "+\t}\n"
@@ -428,7 +427,7 @@
  "+\t\treturn -ENODEV;\n"
  "+\t}\n"
  "+\tnew_fops = fops_get(handler->fops);\n"
- "+\tif (new_fops == NULL) {\n"
+ "+\tif (new_fops = NULL) {\n"
  "+\t\tfops_put(file->f_op);\n"
  "+\t\treturn -ENODEV;\n"
  "+\t}\n"
@@ -700,13 +699,13 @@
  "+\tint ret;\n"
  "+\n"
  "+idr_again:\n"
- "+\tif (unlikely(idr_pre_get(&iio_idr, GFP_KERNEL) == 0))\n"
+ "+\tif (unlikely(idr_pre_get(&iio_idr, GFP_KERNEL) = 0))\n"
  "+\t\treturn -ENOMEM;\n"
  "+\n"
  "+\tspin_lock(&iio_idr_lock);\n"
  "+\tret = idr_get_new(&iio_idr, NULL, &dev_info->id);\n"
  "+\tspin_unlock(&iio_idr_lock);\n"
- "+\tif (unlikely(ret == -EAGAIN))\n"
+ "+\tif (unlikely(ret = -EAGAIN))\n"
  "+\t\tgoto idr_again;\n"
  "+\telse if (unlikely(ret))\n"
  "+\t\treturn ret;\n"
@@ -779,14 +778,14 @@
  "+{\n"
  "+\tint ret = 0, i, j;\n"
  "+\n"
- "+\tif (dev_info->num_interrupt_lines == 0)\n"
+ "+\tif (dev_info->num_interrupt_lines = 0)\n"
  "+\t\treturn 0;\n"
  "+\n"
  "+\tdev_info->event_interfaces = (struct iio_event_interface *)\n"
  "+\t\t(kzalloc(sizeof(struct iio_event_interface)\n"
  "+\t\t\t *dev_info->num_interrupt_lines,\n"
  "+\t\t\t GFP_KERNEL));\n"
- "+\tif (dev_info->event_interfaces == NULL) {\n"
+ "+\tif (dev_info->event_interfaces = NULL) {\n"
  "+\t\tret = -ENOMEM;\n"
  "+\t\tgoto error_ret;\n"
  "+\t}\n"
@@ -799,7 +798,7 @@
  "+\t\t= kzalloc(sizeof(struct iio_interrupt *)\n"
  "+\t\t\t  *dev_info->num_interrupt_lines,\n"
  "+\t\t\t  GFP_KERNEL);\n"
- "+\tif (dev_info->interrupts == NULL) {\n"
+ "+\tif (dev_info->interrupts = NULL) {\n"
  "+\t\tdev_err(dev_info->dev,\n"
  "+\t\t\t\"Failed to register sysfs hooks for events attributes\");\n"
  "+\t\tret = -ENOMEM;\n"
@@ -871,7 +870,7 @@
  "+static void iio_device_unregister_eventset(struct iio_dev *dev_info)\n"
  "+{\n"
  "+\tint i;\n"
- "+\tif (dev_info->num_interrupt_lines == 0)\n"
+ "+\tif (dev_info->num_interrupt_lines = 0)\n"
  "+\t\treturn;\n"
  "+\tfor (i = 0; i < dev_info->num_interrupt_lines; i++)\n"
  "+\t\tsysfs_remove_group(&dev_info->sysfs_dev->kobj,\n"
@@ -1952,6 +1951,11 @@
  "+struct iio_ring_access_funcs {};\n"
  "+#endif /* CONFIG_IIO_RING_BUFFER */\n"
  "+\n"
- +#endif /* _IIO_RING_GENERIC_H_ */
+ "+#endif /* _IIO_RING_GENERIC_H_ */\n"
+ "\n"
+ "_______________________________________________\n"
+ "lm-sensors mailing list\n"
+ "lm-sensors@lm-sensors.org\n"
+ http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
 
-6d6cdd99e57c761308404a2027017df7986a083768ca292affb94563f1e1cb53
+c22f319801d4610bed071db7f90d348add3c747d92b9039b96b8e42d9a7d2c0e

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.