lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CABPqkBS7ceR1jvYq2rHMj0r7MU3yanQqdLN70FibZv+0SA-fBA@mail.gmail.com>
Date:	Wed, 6 Mar 2013 12:20:41 +0100
From:	Stephane Eranian <eranian@...gle.com>
To:	Ingo Molnar <mingo@...nel.org>
Cc:	Li Zefan <lizefan@...wei.com>, LKML <linux-kernel@...r.kernel.org>,
	Cgroups <cgroups@...r.kernel.org>,
	Peter Zijlstra <peterz@...radead.org>,
	Tejun Heo <tj@...nel.org>
Subject: Re: [PATCH] perf: remove include of cgroup.h from perf_event.h

On Wed, Mar 6, 2013 at 11:31 AM, Ingo Molnar <mingo@...nel.org> wrote:
>
> * Stephane Eranian <eranian@...gle.com> wrote:
>
>> > - * This is a per-cpu dynamically allocated data structure.
>> > - */
>> > -struct perf_cgroup_info {
>> > -       u64                             time;
>> > -       u64                             timestamp;
>> > -};
>> > -
>> > -struct perf_cgroup {
>> > -       struct                          cgroup_subsys_state css;
>> > -       struct                          perf_cgroup_info *info; /* timing info, one per cpu */
>> > -};
>> > -#endif
>> > -
>> > +struct perf_cgroup;
>>
>> The problem is that you have struct perf_cgroup in the struct perf_event
>> structure. Today, this field is not referenced outside of kernel/events/core.c But
>> it is available outside this file. If someday the field is reference, your changes
>> will have to do reverted. So I am wondering what is the point of the change right
>> now?
>
> It's standard practice to not define the type for task_struct or other kernel
> subsystems.
>
> For example slab caches can be created via kmem_cache_create() anywhere in the tree,
> but the internal structure is only known to the SLAB subsystem.
>
I am fine with the change.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ