public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: Tonda <as@strmilov.cz>
Cc: viro@zeniv.linux.org.uk, linux-fsdevel@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: Module hiding files controlled by sysfs
Date: Fri, 12 Aug 2011 19:00:08 -0700	[thread overview]
Message-ID: <20110813020008.GA15554@kroah.com> (raw)
In-Reply-To: <1313106903-18702-1-git-send-email-as@strmilov.cz>

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...


  parent reply	other threads:[~2011-08-13  2:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-11 23:55 Module hiding files controlled by sysfs Tonda
2011-08-12  1:20 ` Al Viro
2011-08-13  2:00 ` Greg KH [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-08-11 23:45 Tonda

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110813020008.GA15554@kroah.com \
    --to=greg@kroah.com \
    --cc=as@strmilov.cz \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox