/[smeserver]/cdrom.image/sme9/updates/storage/formats/prepboot.py
ViewVC logotype

Contents of /cdrom.image/sme9/updates/storage/formats/prepboot.py

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (show annotations) (download) (as text)
Sun Dec 22 04:27:52 2013 UTC (10 years, 6 months ago) by wellsi
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +0 -0 lines
Content type: text/x-python
FILE REMOVED
anaconda updates now handled via patches

1 # prepboot.py
2 # Format class for PPC PReP Boot.
3 #
4 # Copyright (C) 2009 Red Hat, Inc.
5 #
6 # This copyrighted material is made available to anyone wishing to use,
7 # modify, copy, or redistribute it subject to the terms and conditions of
8 # the GNU General Public License v.2, or (at your option) any later version.
9 # This program is distributed in the hope that it will be useful, but WITHOUT
10 # ANY WARRANTY expressed or implied, including the implied warranties of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
12 # Public License for more details. You should have received a copy of the
13 # GNU General Public License along with this program; if not, write to the
14 # Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
15 # 02110-1301, USA. Any Red Hat trademarks that are incorporated in the
16 # source code or documentation are not subject to the GNU General Public
17 # License and may only be used or replicated with the express permission of
18 # Red Hat, Inc.
19 #
20 # Red Hat Author(s): Dave Lehman <dlehman@redhat.com>
21 #
22
23 from ..errors import *
24 from . import DeviceFormat, register_device_format
25 from parted import PARTITION_PREP
26
27 class PPCPRePBoot(DeviceFormat):
28 """ Generic device format. """
29 _type = "prepboot"
30 _name = "PPC PReP Boot"
31 _udevTypes = []
32 partedFlag = PARTITION_PREP
33 _formattable = True # can be formatted
34 _linuxNative = True # for clearpart
35 _bootable = True # can be used as boot
36 _maxSize = 10 # maximum size in MB
37 _minSize = 4 # minimum size in MB
38
39 def __init__(self, *args, **kwargs):
40 """ Create a PRePBoot instance.
41
42 Keyword Arguments:
43
44 device -- path to the underlying device
45 exists -- indicates whether this is an existing format
46
47 """
48 DeviceFormat.__init__(self, *args, **kwargs)
49
50 @property
51 def status(self):
52 return False
53
54 @property
55 def supported(self):
56 import platform
57 return isinstance(platform.getPlatform(None), platform.IPSeriesPPC)
58
59 def writeKS(self, f):
60 f.write("prepboot --fstype=%s" % self.type)
61
62
63 register_device_format(PPCPRePBoot)
64

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed