Commit d6444062 authored by Joe Perches's avatar Joe Perches Committed by David S. Miller
Browse files

net: Use octal not symbolic permissions



Prefer the direct use of octal for permissions.

Done with checkpatch -f --types=SYMBOLIC_PERMS --fix-inplace
and some typing.

Miscellanea:

o Whitespace neatening around these conversions.

Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent cb6219a2
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -148,7 +148,7 @@ int __net_init vlan_proc_init(struct net *net)
	if (!vn->proc_vlan_dir)
		goto err;

	vn->proc_vlan_conf = proc_create(name_conf, S_IFREG|S_IRUSR|S_IWUSR,
	vn->proc_vlan_conf = proc_create(name_conf, S_IFREG | 0600,
					 vn->proc_vlan_dir, &vlan_fops);
	if (!vn->proc_vlan_conf)
		goto err;
@@ -172,7 +172,7 @@ int vlan_proc_add_dev(struct net_device *vlandev)
	if (!strcmp(vlandev->name, name_conf))
		return -EINVAL;
	vlan->dent =
		proc_create_data(vlandev->name, S_IFREG|S_IRUSR|S_IWUSR,
		proc_create_data(vlandev->name, S_IFREG | 0600,
				 vn->proc_vlan_dir, &vlandev_fops, vlandev);
	if (!vlan->dent)
		return -ENOBUFS;
+4 −4
Original line number Diff line number Diff line
@@ -257,22 +257,22 @@ int __init atalk_proc_init(void)
	if (!atalk_proc_dir)
		goto out;

	p = proc_create("interface", S_IRUGO, atalk_proc_dir,
	p = proc_create("interface", 0444, atalk_proc_dir,
			&atalk_seq_interface_fops);
	if (!p)
		goto out_interface;

	p = proc_create("route", S_IRUGO, atalk_proc_dir,
	p = proc_create("route", 0444, atalk_proc_dir,
			&atalk_seq_route_fops);
	if (!p)
		goto out_route;

	p = proc_create("socket", S_IRUGO, atalk_proc_dir,
	p = proc_create("socket", 0444, atalk_proc_dir,
			&atalk_seq_socket_fops);
	if (!p)
		goto out_socket;

	p = proc_create("arp", S_IRUGO, atalk_proc_dir, &atalk_seq_arp_fops);
	p = proc_create("arp", 0444, atalk_proc_dir, &atalk_seq_arp_fops);
	if (!p)
		goto out_arp;

+6 −6
Original line number Diff line number Diff line
@@ -96,12 +96,12 @@ static ssize_t show_link_rate(struct device *cdev,
	return scnprintf(buf, PAGE_SIZE, "%d\n", link_rate);
}

static DEVICE_ATTR(address, S_IRUGO, show_address, NULL);
static DEVICE_ATTR(atmaddress, S_IRUGO, show_atmaddress, NULL);
static DEVICE_ATTR(atmindex, S_IRUGO, show_atmindex, NULL);
static DEVICE_ATTR(carrier, S_IRUGO, show_carrier, NULL);
static DEVICE_ATTR(type, S_IRUGO, show_type, NULL);
static DEVICE_ATTR(link_rate, S_IRUGO, show_link_rate, NULL);
static DEVICE_ATTR(address, 0444, show_address, NULL);
static DEVICE_ATTR(atmaddress, 0444, show_atmaddress, NULL);
static DEVICE_ATTR(atmindex, 0444, show_atmindex, NULL);
static DEVICE_ATTR(carrier, 0444, show_carrier, NULL);
static DEVICE_ATTR(type, 0444, show_type, NULL);
static DEVICE_ATTR(link_rate, 0444, show_link_rate, NULL);

static struct device_attribute *atm_attrs[] = {
	&dev_attr_atmaddress,
+1 −1
Original line number Diff line number Diff line
@@ -893,7 +893,7 @@ static int __init atm_clip_init(void)
	{
		struct proc_dir_entry *p;

		p = proc_create("arp", S_IRUGO, atm_proc_root, &arp_seq_fops);
		p = proc_create("arp", 0444, atm_proc_root, &arp_seq_fops);
		if (!p) {
			pr_err("Unable to initialize /proc/net/atm/arp\n");
			atm_clip_exit_noproc();
+1 −1
Original line number Diff line number Diff line
@@ -1042,7 +1042,7 @@ static int __init lane_module_init(void)
#ifdef CONFIG_PROC_FS
	struct proc_dir_entry *p;

	p = proc_create("lec", S_IRUGO, atm_proc_root, &lec_seq_fops);
	p = proc_create("lec", 0444, atm_proc_root, &lec_seq_fops);
	if (!p) {
		pr_err("Unable to initialize /proc/net/atm/lec\n");
		return -ENOMEM;
Loading