All of lore.kernel.org
 help / color / mirror / Atom feed
diff for duplicates of <20080723194230.GE26938@trinity.fluff.org>

diff --git a/a/1.txt b/N1/1.txt
index 4e99b50..048a10d 100644
--- a/a/1.txt
+++ b/N1/1.txt
@@ -933,11 +933,11 @@ more nasty macros.
 > +
 > +	/* 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;
 > +		}
@@ -982,9 +982,8 @@ more nasty macros.
 > +{
 > +	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;
 > +	}
@@ -1038,7 +1037,7 @@ more nasty macros.
 > +
 > +	time_ns = iio_get_time_ns();
 > +	/* detect single element list*/
-> +	if (int_info->ev_list.list.next->next == &int_info->ev_list.list) {
+> +	if (int_info->ev_list.list.next->next = &int_info->ev_list.list) {
 > +		disable_irq_nosync(irq);
 > +		p = list_first_entry(&int_info->ev_list.list,
 > +				     struct iio_event_handler_list,
@@ -1056,7 +1055,7 @@ more nasty macros.
 > +int iio_add_event_to_list(struct iio_event_handler_list *list,
 > +				   struct iio_event_handler_list *el)
 > +{
-> +	if (el->refcount == 0)
+> +	if (el->refcount = 0)
 > +		list_add(&list->list, &el->list);
 > +	el->refcount++;
 > +	return 0;
@@ -1067,7 +1066,7 @@ more nasty macros.
 > +					*el)
 > +{
 > +	el->refcount--;
-> +	if (el->refcount == 0)
+> +	if (el->refcount = 0)
 > +		list_del_init(&el->list);
 > +	return 0;
 > +}
@@ -1080,9 +1079,9 @@ more nasty macros.
 > +
 > +	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;
 > +	}
@@ -1119,7 +1118,7 @@ more nasty macros.
 > +		return -ENODEV;
 > +	}
 > +	new_fops = fops_get(handler->fops);
-> +	if (new_fops == NULL) {
+> +	if (new_fops = NULL) {
 > +		fops_put(file->f_op);
 > +		return -ENODEV;
 > +	}
@@ -1384,13 +1383,13 @@ more nasty macros.
 > +	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;
@@ -1404,7 +1403,7 @@ more nasty macros.
 > +	int id;
 > +
 > +	if (likely(sscanf(dev_info->sysfs_dev->bus_id,
-> +			  IIO_ID_FORMAT, &id) == 1)) {
+> +			  IIO_ID_FORMAT, &id) = 1)) {
 > +		spin_lock(&iio_idr_lock);
 > +		idr_remove(&iio_idr, id);
 > +		spin_unlock(&iio_idr_lock);
@@ -1420,13 +1419,13 @@ more nasty macros.
 > +	struct device_attribute *devattr;
 > +	struct iio_event_attr *indio_devattr;
 > +
-> +	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;
 > +	}
@@ -1439,7 +1438,7 @@ more nasty macros.
 > +		= 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;
@@ -1473,7 +1472,7 @@ more nasty macros.
 > +	   but other than a slight overhead that isn't a problem */
 > +	j = 0;
 > +	while (1) {
-> +		if (dev_info->event_attrs->attrs[j] == NULL)
+> +		if (dev_info->event_attrs->attrs[j] = NULL)
 > +			break;
 > +		devattr = container_of(dev_info->event_attrs->attrs[j],
 > +				       struct device_attribute, attr);
@@ -1497,7 +1496,7 @@ more nasty macros.
 > +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++)
 > +		iio_free_ev_int(&dev_info->event_interfaces[i],
@@ -1516,13 +1515,13 @@ more nasty macros.
 > +
 > +	list_for_each_entry(ptimer_i, &industrialio_ptimer_board_info_list,
 > +			    list)
-> +		if (ptimer_i->inuse == false) {
+> +		if (ptimer_i->inuse = false) {
 > +			ptimer_i->inuse = true;
 > +			*name = ptimer_i->info.name;
 > +			break;
 > +		}
 > +	mutex_unlock(&industrialio_ptimer_board_lock);
-> +	if (*name == NULL)
+> +	if (*name = NULL)
 > +		return -EINVAL;
 > +
 > +	return 0;
@@ -1534,7 +1533,7 @@ more nasty macros.
 > +	mutex_lock(&industrialio_ptimer_board_lock);
 > +	list_for_each_entry(ptimer_i, &industrialio_ptimer_board_info_list,
 > +			    list)
-> +		if (ptimer_i->info.name == name) {
+> +		if (ptimer_i->info.name = name) {
 > +			ptimer_i->inuse = false;
 > +			break;
 > +		}
@@ -1676,7 +1675,7 @@ more nasty macros.
 > +	int ret;
 > +
 > +	ret = rtc_irq_set_freq(ptimer->rtc, &ptimer->task, frequency);
-> +	if (ret == 0)
+> +	if (ret = 0)
 > +		ptimer->frequency = frequency;
 > +
 > +	return ret;
@@ -1726,7 +1725,7 @@ more nasty macros.
 > +
 > +	indio_dev->ptimer = kmalloc(sizeof(struct iio_periodic), GFP_KERNEL);
 > +	indio_dev->ptimer->rtc = rtc_class_open(name);
-> +	if (indio_dev->ptimer == NULL) {
+> +	if (indio_dev->ptimer = NULL) {
 > +		ret = -EINVAL;
 > +		goto error_free_ptimer;
 > +	}
@@ -1872,7 +1871,7 @@ more nasty macros.
 > +	int code;
 > +
 > +	/* initial store */
-> +	if (unlikely(ring->write_p == 0)) {
+> +	if (unlikely(ring->write_p = 0)) {
 > +		ring->write_p = ring->data;
 > +		/* doesn't actually matter if this is out of the set */
 > +		ring->half_p = ring->data - ring->buf.length*ring->buf.size/2;
@@ -1884,18 +1883,18 @@ more nasty macros.
 > +	barrier();
 > +	ring->write_p += ring->buf.size;
 > +	/* End of ring, back to the beginning */
-> +	if (ring->write_p == ring->data + ring->buf.length*ring->buf.size) {
+> +	if (ring->write_p = ring->data + ring->buf.length*ring->buf.size) {
 > +		ring->write_p = ring->data;
 > +		ring->buf.loopcount++;
 > +	}
-> +	if (ring->read_p == 0)
+> +	if (ring->read_p = 0)
 > +		ring->read_p = ring->data;
 > +	/* Buffer full - move the read pointer and create / escalate
 > +	 * ring event */
-> +	else if (ring->write_p == ring->read_p) {
+> +	else if (ring->write_p = ring->read_p) {
 > +		ring->read_p += ring->buf.size;
 > +		if (ring->read_p
-> +		    == ring->data + ring->buf.length*ring->buf.size)
+> +		    = ring->data + ring->buf.length*ring->buf.size)
 > +			ring->read_p = ring->data;
 > +
 > +		spin_lock(ring->buf.shared_ev_pointer.lock);
@@ -1926,9 +1925,9 @@ more nasty macros.
 > +	 * simultaneous read */
 > +	/* Also need to use loop count to ensure this only happens once */
 > +	ring->half_p += ring->buf.size;
-> +	if (ring->half_p == ring->data + ring->buf.length*ring->buf.size)
+> +	if (ring->half_p = ring->data + ring->buf.length*ring->buf.size)
 > +		ring->half_p = ring->data;
-> +	if (ring->half_p == ring->read_p) {
+> +	if (ring->half_p = ring->read_p) {
 > +		spin_lock(ring->buf.shared_ev_pointer.lock);
 > +		code = IIO_EVENT_CODE_RING_50_FULL;
 > +		ret = __iio_put_event(&ring->buf.ev_int,
@@ -2023,14 +2022,14 @@ more nasty macros.
 > +	if (bytes_to_rip > ring->buf.size*ring->buf.length)
 > +		bytes_to_rip = ring->buf.size*ring->buf.length;
 > +	data_cpy = kmalloc(bytes_to_rip, GFP_KERNEL);
-> +	if (data_cpy == NULL) {
+> +	if (data_cpy = NULL) {
 > +		ret = -ENOMEM;
 > +		goto error_ret;
 > +	}
 > +
 > +	/* build local copy */
 > +	initial_read_p = ring->read_p;
-> +	if (unlikely(initial_read_p == 0)) {
+> +	if (unlikely(initial_read_p = 0)) {
 > +		/* No data here as yet */
 > +		ret = 0;
 > +		goto error_free_data_cpy;
@@ -2043,7 +2042,7 @@ more nasty macros.
 > +		initial_read_p = ring->read_p;
 > +		initial_write_p = ring->write_p;
 > +	}
-> +	if (initial_write_p == initial_read_p) {
+> +	if (initial_write_p = initial_read_p) {
 > +		/* No new data available.*/
 > +		ret = 0;
 > +		goto error_free_data_cpy;
@@ -2130,7 +2129,7 @@ more nasty macros.
 > +
 > +/* Create and register the event character device */
 > +	buf->event_minor_name = kmalloc(20, GFP_KERNEL);
-> +	if (buf->event_minor_name == NULL) {
+> +	if (buf->event_minor_name = NULL) {
 > +		ret = -ENOMEM;
 > +		goto error_ret;
 > +	}
@@ -2167,7 +2166,7 @@ more nasty macros.
 > +	int ret;
 > +/* Create and register the access character device */
 > +	buf->access_minor_name = kmalloc(20, GFP_KERNEL);
-> +	if (buf->access_minor_name == NULL) {
+> +	if (buf->access_minor_name = NULL) {
 > +		ret = -ENOMEM;
 > +		goto error_ret;
 > +	}
@@ -2221,7 +2220,7 @@ more nasty macros.
 > +	*ring = kmalloc(sizeof(struct iio_hw_ring_buffer),
 > +			GFP_KERNEL);
 > +
-> +	if (*ring == NULL) {
+> +	if (*ring = NULL) {
 > +		ret = -ENOMEM;
 > +		goto error_ret;
 > +	}
@@ -2285,7 +2284,7 @@ more nasty macros.
 > +	kfree(ring->data);
 > +	/* keeps clear of chr devs etc - so fine to use here - I THINK!*/
 > +	INIT_IIO_SW_RING_BUFFER(ring, bytes_per_datum, length);
-> +	if (ring->data == NULL)
+> +	if (ring->data = NULL)
 > +		ret = -ENOMEM;
 > +
 > +error_ret:
@@ -2318,7 +2317,7 @@ more nasty macros.
 > +	/* Actually do the ring buffer initialization */
 > +	*ring = kzalloc(sizeof(struct iio_sw_ring_buffer),
 > +			GFP_KERNEL);
-> +	if (*ring == NULL) {
+> +	if (*ring = NULL) {
 > +		ret = -ENOMEM;
 > +		goto error_ret;
 > +	}
@@ -2432,11 +2431,11 @@ more nasty macros.
 > +	struct iio_dev *dev_info = dev_get_drvdata(dev);
 > +
 > +	mutex_lock(&dev_info->mlock);
-> +	requested_state = (buf[0] == '0') ? 0 : 1;
+> +	requested_state = (buf[0] = '0') ? 0 : 1;
 > +	current_state = (dev_info->currentmode
 > +			 & (INDIO_RING_DATA_RDY | INDIO_RING_POLLED))
 > +			 ? 1: 0;
-> +	if (current_state == requested_state)
+> +	if (current_state = requested_state)
 > +		goto done;
 > +	if (requested_state) {
 > +		if (dev_info->ring_preenable) {
@@ -2560,3 +2559,9 @@ Ben
 
 Q:      What's a light-year?
 A:      One-third less calories than a regular year.
+
+
+_______________________________________________
+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 5cf7929..8e41341 100644
--- a/a/content_digest
+++ b/N1/content_digest
@@ -1,8 +1,8 @@
  "ref\0488763AD.4050400@gmail.com\0"
  "ref\0488765A5.3040703@gmail.com\0"
  "From\0Ben Dooks <ben-linux@fluff.org>\0"
- "Subject\0Re: [spi-devel-general] [Patch 1/4] Industrialio Core\0"
- "Date\0Wed, 23 Jul 2008 20:42:30 +0100\0"
+ "Subject\0Re: [lm-sensors] [spi-devel-general] [Patch 1/4] Industrialio Core\0"
+ "Date\0Wed, 23 Jul 2008 19:42:30 +0000\0"
  "To\0Jonathan Cameron <Jonathan.Cameron@gmail.com>\0"
  "Cc\0LKML <linux-kernel@vger.kernel.org>"
   spi-devel-general@lists.sourceforge.net
@@ -950,11 +950,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"
@@ -999,9 +999,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"
@@ -1055,7 +1054,7 @@
  "> +\n"
  "> +\ttime_ns = iio_get_time_ns();\n"
  "> +\t/* detect single element list*/\n"
- "> +\tif (int_info->ev_list.list.next->next == &int_info->ev_list.list) {\n"
+ "> +\tif (int_info->ev_list.list.next->next = &int_info->ev_list.list) {\n"
  "> +\t\tdisable_irq_nosync(irq);\n"
  "> +\t\tp = list_first_entry(&int_info->ev_list.list,\n"
  "> +\t\t\t\t     struct iio_event_handler_list,\n"
@@ -1073,7 +1072,7 @@
  "> +int iio_add_event_to_list(struct iio_event_handler_list *list,\n"
  "> +\t\t\t\t   struct iio_event_handler_list *el)\n"
  "> +{\n"
- "> +\tif (el->refcount == 0)\n"
+ "> +\tif (el->refcount = 0)\n"
  "> +\t\tlist_add(&list->list, &el->list);\n"
  "> +\tel->refcount++;\n"
  "> +\treturn 0;\n"
@@ -1084,7 +1083,7 @@
  "> +\t\t\t\t\t*el)\n"
  "> +{\n"
  "> +\tel->refcount--;\n"
- "> +\tif (el->refcount == 0)\n"
+ "> +\tif (el->refcount = 0)\n"
  "> +\t\tlist_del_init(&el->list);\n"
  "> +\treturn 0;\n"
  "> +}\n"
@@ -1097,9 +1096,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"
@@ -1136,7 +1135,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"
@@ -1401,13 +1400,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"
@@ -1421,7 +1420,7 @@
  "> +\tint id;\n"
  "> +\n"
  "> +\tif (likely(sscanf(dev_info->sysfs_dev->bus_id,\n"
- "> +\t\t\t  IIO_ID_FORMAT, &id) == 1)) {\n"
+ "> +\t\t\t  IIO_ID_FORMAT, &id) = 1)) {\n"
  "> +\t\tspin_lock(&iio_idr_lock);\n"
  "> +\t\tidr_remove(&iio_idr, id);\n"
  "> +\t\tspin_unlock(&iio_idr_lock);\n"
@@ -1437,13 +1436,13 @@
  "> +\tstruct device_attribute *devattr;\n"
  "> +\tstruct iio_event_attr *indio_devattr;\n"
  "> +\n"
- "> +\tif (dev_info->num_interrupt_lines == 0)\n"
+ "> +\tif (dev_info->num_interrupt_lines = 0)\n"
  "> +\t\treturn 0;\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"
@@ -1456,7 +1455,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"
@@ -1490,7 +1489,7 @@
  "> +\t   but other than a slight overhead that isn't a problem */\n"
  "> +\tj = 0;\n"
  "> +\twhile (1) {\n"
- "> +\t\tif (dev_info->event_attrs->attrs[j] == NULL)\n"
+ "> +\t\tif (dev_info->event_attrs->attrs[j] = NULL)\n"
  "> +\t\t\tbreak;\n"
  "> +\t\tdevattr = container_of(dev_info->event_attrs->attrs[j],\n"
  "> +\t\t\t\t       struct device_attribute, attr);\n"
@@ -1514,7 +1513,7 @@
  "> +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\tiio_free_ev_int(&dev_info->event_interfaces[i],\n"
@@ -1533,13 +1532,13 @@
  "> +\n"
  "> +\tlist_for_each_entry(ptimer_i, &industrialio_ptimer_board_info_list,\n"
  "> +\t\t\t    list)\n"
- "> +\t\tif (ptimer_i->inuse == false) {\n"
+ "> +\t\tif (ptimer_i->inuse = false) {\n"
  "> +\t\t\tptimer_i->inuse = true;\n"
  "> +\t\t\t*name = ptimer_i->info.name;\n"
  "> +\t\t\tbreak;\n"
  "> +\t\t}\n"
  "> +\tmutex_unlock(&industrialio_ptimer_board_lock);\n"
- "> +\tif (*name == NULL)\n"
+ "> +\tif (*name = NULL)\n"
  "> +\t\treturn -EINVAL;\n"
  "> +\n"
  "> +\treturn 0;\n"
@@ -1551,7 +1550,7 @@
  "> +\tmutex_lock(&industrialio_ptimer_board_lock);\n"
  "> +\tlist_for_each_entry(ptimer_i, &industrialio_ptimer_board_info_list,\n"
  "> +\t\t\t    list)\n"
- "> +\t\tif (ptimer_i->info.name == name) {\n"
+ "> +\t\tif (ptimer_i->info.name = name) {\n"
  "> +\t\t\tptimer_i->inuse = false;\n"
  "> +\t\t\tbreak;\n"
  "> +\t\t}\n"
@@ -1693,7 +1692,7 @@
  "> +\tint ret;\n"
  "> +\n"
  "> +\tret = rtc_irq_set_freq(ptimer->rtc, &ptimer->task, frequency);\n"
- "> +\tif (ret == 0)\n"
+ "> +\tif (ret = 0)\n"
  "> +\t\tptimer->frequency = frequency;\n"
  "> +\n"
  "> +\treturn ret;\n"
@@ -1743,7 +1742,7 @@
  "> +\n"
  "> +\tindio_dev->ptimer = kmalloc(sizeof(struct iio_periodic), GFP_KERNEL);\n"
  "> +\tindio_dev->ptimer->rtc = rtc_class_open(name);\n"
- "> +\tif (indio_dev->ptimer == NULL) {\n"
+ "> +\tif (indio_dev->ptimer = NULL) {\n"
  "> +\t\tret = -EINVAL;\n"
  "> +\t\tgoto error_free_ptimer;\n"
  "> +\t}\n"
@@ -1889,7 +1888,7 @@
  "> +\tint code;\n"
  "> +\n"
  "> +\t/* initial store */\n"
- "> +\tif (unlikely(ring->write_p == 0)) {\n"
+ "> +\tif (unlikely(ring->write_p = 0)) {\n"
  "> +\t\tring->write_p = ring->data;\n"
  "> +\t\t/* doesn't actually matter if this is out of the set */\n"
  "> +\t\tring->half_p = ring->data - ring->buf.length*ring->buf.size/2;\n"
@@ -1901,18 +1900,18 @@
  "> +\tbarrier();\n"
  "> +\tring->write_p += ring->buf.size;\n"
  "> +\t/* End of ring, back to the beginning */\n"
- "> +\tif (ring->write_p == ring->data + ring->buf.length*ring->buf.size) {\n"
+ "> +\tif (ring->write_p = ring->data + ring->buf.length*ring->buf.size) {\n"
  "> +\t\tring->write_p = ring->data;\n"
  "> +\t\tring->buf.loopcount++;\n"
  "> +\t}\n"
- "> +\tif (ring->read_p == 0)\n"
+ "> +\tif (ring->read_p = 0)\n"
  "> +\t\tring->read_p = ring->data;\n"
  "> +\t/* Buffer full - move the read pointer and create / escalate\n"
  "> +\t * ring event */\n"
- "> +\telse if (ring->write_p == ring->read_p) {\n"
+ "> +\telse if (ring->write_p = ring->read_p) {\n"
  "> +\t\tring->read_p += ring->buf.size;\n"
  "> +\t\tif (ring->read_p\n"
- "> +\t\t    == ring->data + ring->buf.length*ring->buf.size)\n"
+ "> +\t\t    = ring->data + ring->buf.length*ring->buf.size)\n"
  "> +\t\t\tring->read_p = ring->data;\n"
  "> +\n"
  "> +\t\tspin_lock(ring->buf.shared_ev_pointer.lock);\n"
@@ -1943,9 +1942,9 @@
  "> +\t * simultaneous read */\n"
  "> +\t/* Also need to use loop count to ensure this only happens once */\n"
  "> +\tring->half_p += ring->buf.size;\n"
- "> +\tif (ring->half_p == ring->data + ring->buf.length*ring->buf.size)\n"
+ "> +\tif (ring->half_p = ring->data + ring->buf.length*ring->buf.size)\n"
  "> +\t\tring->half_p = ring->data;\n"
- "> +\tif (ring->half_p == ring->read_p) {\n"
+ "> +\tif (ring->half_p = ring->read_p) {\n"
  "> +\t\tspin_lock(ring->buf.shared_ev_pointer.lock);\n"
  "> +\t\tcode = IIO_EVENT_CODE_RING_50_FULL;\n"
  "> +\t\tret = __iio_put_event(&ring->buf.ev_int,\n"
@@ -2040,14 +2039,14 @@
  "> +\tif (bytes_to_rip > ring->buf.size*ring->buf.length)\n"
  "> +\t\tbytes_to_rip = ring->buf.size*ring->buf.length;\n"
  "> +\tdata_cpy = kmalloc(bytes_to_rip, GFP_KERNEL);\n"
- "> +\tif (data_cpy == NULL) {\n"
+ "> +\tif (data_cpy = NULL) {\n"
  "> +\t\tret = -ENOMEM;\n"
  "> +\t\tgoto error_ret;\n"
  "> +\t}\n"
  "> +\n"
  "> +\t/* build local copy */\n"
  "> +\tinitial_read_p = ring->read_p;\n"
- "> +\tif (unlikely(initial_read_p == 0)) {\n"
+ "> +\tif (unlikely(initial_read_p = 0)) {\n"
  "> +\t\t/* No data here as yet */\n"
  "> +\t\tret = 0;\n"
  "> +\t\tgoto error_free_data_cpy;\n"
@@ -2060,7 +2059,7 @@
  "> +\t\tinitial_read_p = ring->read_p;\n"
  "> +\t\tinitial_write_p = ring->write_p;\n"
  "> +\t}\n"
- "> +\tif (initial_write_p == initial_read_p) {\n"
+ "> +\tif (initial_write_p = initial_read_p) {\n"
  "> +\t\t/* No new data available.*/\n"
  "> +\t\tret = 0;\n"
  "> +\t\tgoto error_free_data_cpy;\n"
@@ -2147,7 +2146,7 @@
  "> +\n"
  "> +/* Create and register the event character device */\n"
  "> +\tbuf->event_minor_name = kmalloc(20, GFP_KERNEL);\n"
- "> +\tif (buf->event_minor_name == NULL) {\n"
+ "> +\tif (buf->event_minor_name = NULL) {\n"
  "> +\t\tret = -ENOMEM;\n"
  "> +\t\tgoto error_ret;\n"
  "> +\t}\n"
@@ -2184,7 +2183,7 @@
  "> +\tint ret;\n"
  "> +/* Create and register the access character device */\n"
  "> +\tbuf->access_minor_name = kmalloc(20, GFP_KERNEL);\n"
- "> +\tif (buf->access_minor_name == NULL) {\n"
+ "> +\tif (buf->access_minor_name = NULL) {\n"
  "> +\t\tret = -ENOMEM;\n"
  "> +\t\tgoto error_ret;\n"
  "> +\t}\n"
@@ -2238,7 +2237,7 @@
  "> +\t*ring = kmalloc(sizeof(struct iio_hw_ring_buffer),\n"
  "> +\t\t\tGFP_KERNEL);\n"
  "> +\n"
- "> +\tif (*ring == NULL) {\n"
+ "> +\tif (*ring = NULL) {\n"
  "> +\t\tret = -ENOMEM;\n"
  "> +\t\tgoto error_ret;\n"
  "> +\t}\n"
@@ -2302,7 +2301,7 @@
  "> +\tkfree(ring->data);\n"
  "> +\t/* keeps clear of chr devs etc - so fine to use here - I THINK!*/\n"
  "> +\tINIT_IIO_SW_RING_BUFFER(ring, bytes_per_datum, length);\n"
- "> +\tif (ring->data == NULL)\n"
+ "> +\tif (ring->data = NULL)\n"
  "> +\t\tret = -ENOMEM;\n"
  "> +\n"
  "> +error_ret:\n"
@@ -2335,7 +2334,7 @@
  "> +\t/* Actually do the ring buffer initialization */\n"
  "> +\t*ring = kzalloc(sizeof(struct iio_sw_ring_buffer),\n"
  "> +\t\t\tGFP_KERNEL);\n"
- "> +\tif (*ring == NULL) {\n"
+ "> +\tif (*ring = NULL) {\n"
  "> +\t\tret = -ENOMEM;\n"
  "> +\t\tgoto error_ret;\n"
  "> +\t}\n"
@@ -2449,11 +2448,11 @@
  "> +\tstruct iio_dev *dev_info = dev_get_drvdata(dev);\n"
  "> +\n"
  "> +\tmutex_lock(&dev_info->mlock);\n"
- "> +\trequested_state = (buf[0] == '0') ? 0 : 1;\n"
+ "> +\trequested_state = (buf[0] = '0') ? 0 : 1;\n"
  "> +\tcurrent_state = (dev_info->currentmode\n"
  "> +\t\t\t & (INDIO_RING_DATA_RDY | INDIO_RING_POLLED))\n"
  "> +\t\t\t ? 1: 0;\n"
- "> +\tif (current_state == requested_state)\n"
+ "> +\tif (current_state = requested_state)\n"
  "> +\t\tgoto done;\n"
  "> +\tif (requested_state) {\n"
  "> +\t\tif (dev_info->ring_preenable) {\n"
@@ -2576,6 +2575,12 @@
  "Ben\n"
  "\n"
  "Q:      What's a light-year?\n"
- A:      One-third less calories than a regular year.
+ "A:      One-third less calories than a regular year.\n"
+ "\n"
+ "\n"
+ "_______________________________________________\n"
+ "lm-sensors mailing list\n"
+ "lm-sensors@lm-sensors.org\n"
+ http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
 
-b2993e360d9d41b6648ad4307dea19f18db7e615e0f46a21d4af4371700ab785
+83eaf95b6b4ffd2f29e254afa4ec3ba404357afed0852aa761c97ddb7390c271

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.