On Wed, Apr 12, 2017 at 2:46 PM, Mandeep Sandhu <mandeepsandhu....@gmail.com > wrote:
> On Wed, Apr 12, 2017 at 2:41 PM, Code Soldier1 <codesoldi...@gmail.com> > wrote: > >> Yes that is possible but it is very time consuming. Let's say I get >> 500 hits ? Try searching for destructor in linux kernel code. I am >> only interested in the one that is defined in sk_buff. >> > > Look at cscope & ctags for such queries. Both tools will list all > instances where the said identifier is declared. If a field is defined in > multiple structs, you will get multiple results from which you have to sift > through (it will still be less than free-text search that you'd do on lxr > though). > > Also, please reply to the list (and not to me directly). Others on this > list might have better suggestions. > (and I myself forgot to CC the list! :P) -mandeep > HTH, > -mandeep > > > >> >> On Wed, Apr 12, 2017 at 2:28 PM, Mandeep Sandhu >> <mandeepsandhu....@gmail.com> wrote: >> > On Wed, Apr 12, 2017 at 2:25 PM, Code Soldier1 <codesoldi...@gmail.com> >> > wrote: >> >> >> >> Thanks. This does not completely solve my issue. I am looking for >> >> something that can associate a field name with the structure. >> > >> > >> > Well, you can search for a field's use using free-text search, then >> looks at >> > the line of code to figure out what struct it's part of, no? :) >> > >> > -mandeep >> > >> > >> >> >> >> >> >> On Tue, Apr 11, 2017 at 1:13 PM, Mandeep Sandhu >> >> <mandeepsandhu....@gmail.com> wrote: >> >> >> >> >> >> I am looking for something that can list all the places that a >> certain >> >> >> field of a certain structure is used. For example, sk_buff has a >> field >> >> >> called destructor, but so do many other data structures. How do I >> >> >> search for places where just the destructor field of sk_buff. >> >> > >> >> > >> >> > I think lxr has an identifier & free-text search (powered by >> google). If >> >> > that doesn't do it for you, you can go "old school" and try cscope >> >> > maybe? >> >> > >> >> > HTH, >> >> > -mandeep >> >> > >> >> > >> >> >> >> >> >> >> >> >> Thanks a lot. >> >> >> >> >> >> -- >> >> >> CS1 >> >> >> >> >> >> _______________________________________________ >> >> >> Kernelnewbies mailing list >> >> >> Kernelnewbies@kernelnewbies.org >> >> >> https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies >> >> > >> >> > >> >> >> >> >> >> >> >> -- >> >> CS1 >> > >> > >> >> >> >> -- >> CS1 >> > >
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies