lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20140507144248.cf3d5e7411186e2cd616ded8@linux-foundation.org>
Date:	Wed, 7 May 2014 14:42:48 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Raghavendra Ganiga <ravi23ganiga@...il.com>
Cc:	a.zummo@...ertech.it, rtc-linux@...glegroups.com,
	linux-kernel@...r.kernel.org, Alan Cox <alan@...rguk.ukuu.org.uk>
Subject: Re: [PATCH] rtc: add support for maxim dallas rtc ds1343 and ds1344

On Wed,  7 May 2014 00:33:56 +0530 Raghavendra Ganiga <ravi23ganiga@...il.com> wrote:

> This is a patch to add support for
> maxim dallas rtc ds1343 and ds1344
> 
> ...
>
> +static int ds1343_ioctl(struct device *dev, unsigned int cmd, unsigned long arg)
> +{
> +	switch (cmd) {
> +#ifdef RTC_SET_CHARGE
> +	case RTC_SET_CHARGE:
> +	{
> +		int val;
> +
> +		if (copy_from_user(&val, (int __user *)arg, sizeof(int)))
> +			return -EFAULT;
> +
> +		return regmap_write(priv->map, DS1343_TRICKLE_REG, val);
> +	}
> +	break;
> +#endif
> +	}

Why is RTC_SET_CHARGE defined only for m32r?  It seems pretty generic?

> +	return -ENOIOCTLCMD;
> +}

It's possible that this should be -ENOTTY.  I always forget the rule,
but Alan never forgets anything ;)

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ