Re: [patch] IBM HDAPS accelerometer driver, with probing.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Aug 26, 2005 at 06:18:45PM -0400, Robert Love wrote:
> Attached patch provides a driver for the IBM Hard Drive Active
> Protection System (hdaps) on top of 2.6.13-rc6-mm2.

> --- linux-2.6.13-rc6-mm2/drivers/hwmon/hdaps.c
> +++ linux/drivers/hwmon/hdaps.c

> +static int hdaps_probe(struct device *dev)
> +{
> +	int ret;
> +
> +	ret = accelerometer_init();
> +	if (unlikely(ret))

What's the point of having unlikely() attached to every possible if ()?

> +static ssize_t hdaps_temp_show(struct device *dev,
> +			       struct device_attribute *attr, char *buf)
> +{
> +	u8 temp;
> +	int ret;
> +
> +	ret = accelerometer_readb_one(HDAPS_PORT_TEMP, &temp);
> +	if (unlikely(ret < 0))

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]
  Powered by Linux