From: Calvin Walton <calvin.walton@gmail.com>
To: Zhaohui Wang <zwange@gmu.edu>
Cc: linux-newbie@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: how to find when a symbol introduced into the kernel
Date: Sun, 15 Jun 2008 09:37:24 -0400 [thread overview]
Message-ID: <1213537044.25647.4.camel@zem> (raw)
In-Reply-To: <000b01c8ce6b$a7bfda50$f73f8ef0$@edu>
On Sat, 2008-06-14 at 18:11 -0400, Zhaohui Wang wrote:
>
> Hi all
>
> To write multiple kernel version compatible programs, I need to know when a specific symbol (a struct or a function)were introduced in to the kernel tree
>
> Binary search against multiple kernel sources is a way,but is still slow.Is there any fast way to use modern git technology to make my life easier?
>
> Many thanks.
You're probably looking for the command
git log -S functionname
a.k.a. the git pickaxe.
That will show you all of the commits that added or removed a line
containing the name you're interested in, and you can then check just
those changes to see what compatibility may have changed.
To find out what kernel release one of those commits went into, you can
use
git describe <sha1-hash>
and it will report the last tagged kernel version before that commit was
added.
Hope that helps!
--
Calvin Walton <calvin.walton@gmail.com>
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs
next prev parent reply other threads:[~2008-06-15 13:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-14 22:11 how to find when a symbol introduced into the kernel Zhaohui Wang
2008-06-15 8:08 ` Ben Nizette
2008-06-15 13:37 ` Calvin Walton [this message]
2009-02-19 14:28 ` Zhaohui Wang
-- strict thread matches above, loose matches on Subject: below --
2008-05-19 10:57 (unknown) Alexei Babich
2008-05-27 5:24 ` Peter Teoh
2008-05-30 11:06 ` Re: Alexei Babich
2008-06-14 21:51 ` how to find when a symbol introduced into the kernel Zhaohui Wang
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=1213537044.25647.4.camel@zem \
--to=calvin.walton@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-newbie@vger.kernel.org \
--cc=zwange@gmu.edu \
/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