Linux SPARSE checker discussions
 help / color / mirror / Atom feed
From: Yoann Padioleau <padator@wanadoo.fr>
To: linux-sparse@vger.kernel.org
Subject: contextual attributes
Date: Mon, 17 Nov 2008 15:47:28 -0600	[thread overview]
Message-ID: <8763mmuirz.fsf@aryx.cs.uiuc.edu> (raw)



Hi, 

Is it possible by using the __attribute((context(x,y)) sparse
attribute to enforce statically that all the callers of 
certain functions do certain actions such as disabling interrupts ?

I would like an attribute like __assume_disabled_interrupt and 
have such programs:


int __assume_disabled_interrupt    
startpoint() 
{
	return 1;
}


int f1ok()
{
	spin_lock_irq();
	startpoint();
	spin_unlock_irq();
}


int f1bad()
{
	startpoint();
}


             reply	other threads:[~2008-11-17 21:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-17 21:47 Yoann Padioleau [this message]
2008-11-17 22:10 ` contextual attributes Johannes Berg

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=8763mmuirz.fsf@aryx.cs.uiuc.edu \
    --to=padator@wanadoo.fr \
    --cc=linux-sparse@vger.kernel.org \
    /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