From: Jerone Young <jyoung5@us.ibm.com>
To: xen-devel <xen-devel@lists.xensource.com>
Subject: code question?
Date: Thu, 11 Aug 2005 10:55:16 -0500 [thread overview]
Message-ID: <1123775716.3043.15.camel@thinkpad> (raw)
Doing some janitorial (you cleaning the flooded toilets and such) work
today. I have come across this line of code that really I'm not sure
what the intent was..in xen/include/sched.h
#define hypercall_preempt_check() (unlikely( \
softirq_pending(smp_processor_id()) | \
(!!current->vcpu_info->evtchn_upcall_pending & \
!current->vcpu_info->evtchn_upcall_mask) \
))
the part where we have !!current->vcpu_info_evtchen_upcall pending
should this be..should the "!! just be "!"?
And if so shouldn't this just be changed to
#define hypercall_preempt_check() (unlikely( \
softirq_pending(smp_processor_id()) | \
(!(current->vcpu_info->evtchn_upcall_pending & \
current->vcpu_info->evtchn_upcall_mask)) \
))
In a lot of the code in Xen we are using the "!" operator with bitwise
operations..this is one of those examples.
--
Jerone Young
IBM Linux Technology Center
jyoung5@us.ibm.com
512-838-1157 (T/L: 678-1157)
next reply other threads:[~2005-08-11 15:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-11 15:55 Jerone Young [this message]
2005-08-11 16:18 ` code question? Anthony Liguori
2005-08-11 16:22 ` Keir Fraser
2005-08-11 18:14 ` Tim Newsham
2005-08-11 16:55 ` David Hopwood
2005-08-11 17:03 ` M.A. Williamson
2005-08-11 17:23 ` Keir Fraser
2005-08-11 18:53 ` David Hopwood
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=1123775716.3043.15.camel@thinkpad \
--to=jyoung5@us.ibm.com \
--cc=xen-devel@lists.xensource.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.