From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavel Emelyanov Subject: Re: [RFC][PATCH] Devices visibility container Date: Tue, 25 Sep 2007 12:00:07 +0400 Message-ID: <46F8C007.1090000@openvz.org> References: <46F77523.9020001@openvz.org> <6599ad830709250053m715a1848mf6c17a6dd321092@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <6599ad830709250053m715a1848mf6c17a6dd321092-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Paul Menage Cc: Linux Containers , "Eric W. Biederman" List-Id: containers.vger.kernel.org Paul Menage wrote: > On 9/24/07, Pavel Emelyanov wrote: >> # /bin/echo -n '+1:5' > /cont/devs/0/devices.char >> >> More generally, the '+:' string grants access to >> some device, and '-:' disables one. > > How about a more forward-compatible API: > > :=[,:] I'd rather make it look like :[:][::] where :=[r-][w-] and NULL means rw this would keep current API compatible and allow it for extension. > This would allow you the control the access that each cgroup has to a > given device (permissions of 0 indicates that the device isn't even > visible, i.e. the same as your "-:" operation. For now > specifying the (optional) remapping could just fail, but at least the > API would be defined. > > Paul >