Re: Module hiding files controlled by sysfs

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

 



On Fri, Aug 12, 2011 at 01:55:03AM +0200, Tonda wrote:
> diff --git a/fs/hidefiles/hidefiles.c b/fs/hidefiles/hidefiles.c

You forgot your Signed-off-by: line and the rest of the changelog
information explaining what this is, why we would want it, and how you
are going to maintain it.

> +static void disable_write_protection(void)
> +{
> +	unsigned long value;
> +	asm volatile("mov %%cr0,%0" : "=r"(value));
> +	value &= (~WRITEABLE);
> +	asm volatile("mov %0,%%cr0" : : "r"(value));
> +}
> +
> +static void enable_write_protection(void)
> +{
> +	unsigned long value;
> +	asm volatile("mov %%cr0,%0" : "=r"(value));
> +	value |= WRITEABLE;
> +	asm volatile ("mov %0,%%cr0" : : "r"(value));
> +}

Fun stuff, you can do nasty things to a system with this...

--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux