[blivet:master 19/21] Don't notify the kernel if it was tmpfs filesystem that was resized.

Anne Mulhern amulhern at redhat.com
Tue Jan 20 20:21:35 UTC 2015





----- Original Message -----
> From: "David Lehman" <dlehman at redhat.com>
> To: anaconda-patches at lists.fedorahosted.org
> Sent: Tuesday, January 20, 2015 1:29:52 PM
> Subject: Re: [blivet:master 19/21] Don't notify the kernel if it was tmpfs	filesystem that was resized.
> 
> On 01/15/2015 12:39 PM, mulhern wrote:
> > The kernel should notice a resize of a tmpfs filesystem, since that type
> > of filesystem resides in the kernel's memory.
> >
> > And, our current method of notifying the kernel will result in an
> > exception being raised in the case of tmpfs.
> >
> > Signed-off-by: mulhern <amulhern at redhat.com>
> > ---
> >   blivet/formats/fs.py | 3 ++-
> >   1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/blivet/formats/fs.py b/blivet/formats/fs.py
> > index 9effed6..dc4d8a9 100644
> > --- a/blivet/formats/fs.py
> > +++ b/blivet/formats/fs.py
> > @@ -519,7 +519,8 @@ class FS(DeviceFormat):
> >
> >           # XXX must be a smarter way to do this
> >           self._size = self.targetSize
> > -        self.notifyKernel()
> > +        if not self.device == "tmpfs":
> 
> if self.device != "tmpfs" reads better.
> 
> > +            self.notifyKernel()
> >
> >       def _getCheckArgs(self):
> >           argv = []
> >
> 
> _______________________________________________
> anaconda-patches mailing list
> anaconda-patches at lists.fedorahosted.org
> https://lists.fedorahosted.org/mailman/listinfo/anaconda-patches
> 

Done.

- mulhern


More information about the anaconda-patches mailing list