Brian Behlendorf
c4726e7ad2
Merge branch 'linux-user-disk' into refs/top-bases/linux-zfs-branch
2009-10-14 16:32:16 -07:00
Brian Behlendorf
992be351d5
Changes required to integrate libefi in to Linux.
...
The major change here is to fix up libefi to be linux aware. For
the most part this wasn't too hard but there were a few major issues.
First off I needed to handle the DKIOCGMEDIAINFO and DKIOCINFO ioctls.
There is no direct equivilant for these ioctls under linux. To handle
this I added wrapper functions which under Solaris simple call the ioctls.
But under Linux dig around the system a little bit getting the needed
info to fill in the requested structures.
Secondly the efi_ioctl() call was adapted such that under linux it directly
read or writes out the partition table. Under Solaris this work was
handed off to the kernel via an ioctl. In the efi_write() case we also
ensure we prompt the kernel via BLKRRPART to re-scan the new partition
table. The libefi generated partition tables are correct but older
versions of ~parted-1.8.1 can not read them without a small patch.
The kernel and fdisk are able to read them just fine.
Thirdly efi_alloc_and_init() which is used by zpool to determine if a
device is a 'wholedisk' was updated to be linux aware. This check is
performed by using the partition number for the device, which the
partition number is 0 on linux it is a 'wholedisk'. However, certain
device type such as the loopback and ram disks needed to be excluded
because they do not support partitioning.
Forthly the zpool command was made symlink aware so it can correctly
resolve udev entries such as /dev/disk/by-*/*. This symlinks are
fully expanded ensuring all block devices are recognized. When a
when a 'wholedisk' block device is detected we now properly write
out an efi label and place zfs in the first partition (0th slice).
This partition is created 1MiB in to the disk to ensure it is aligned
nicely with all high end block devices I'm aware of.
This all works for me now but it did take quite a bit of work to get
it all sorted out. It would not surprise me if certain special cases
were missed so we should keep any eye of for any odd behavior.
2009-10-14 16:07:48 -07:00
Brian Behlendorf
6ef15db027
Merge branch 'linux-have-libefi' into refs/top-bases/linux-zfs-branch
2009-10-09 15:03:50 -07:00
Brian Behlendorf
f73cff230f
Reverting changes on linux-have-libefi topic branch.
2009-10-09 14:59:05 -07:00
Brian Behlendorf
15c4a8be0c
Merge branch 'linux-have-libefi' into refs/top-bases/linux-zfs-branch
2009-07-07 15:35:07 -07:00
Brian Behlendorf
31157f3a90
Disable zpool_relabel_disk() which requires libefi until we have it.
2009-07-07 15:26:39 -07:00
Brian Behlendorf
23e01e6cde
Merge branch 'linux-user-disk' into refs/top-bases/linux-zfs-branch
2009-07-07 15:07:37 -07:00
Brian Behlendorf
24402e5c15
Drop duplicate defines
2009-07-07 14:58:56 -07:00
Brian Behlendorf
409cfe5051
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
...
Conflicts:
lib/libzfs/libzfs_pool.c
2009-07-06 15:05:47 -07:00
Brian Behlendorf
053043b2d0
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
...
Conflicts:
lib/libzfs/libzfs_pool.c
2009-07-06 13:44:19 -07:00
Brian Behlendorf
149c4b2731
Merge branch 'linux-arc' into refs/top-bases/linux-zfs-branch
...
Conflicts:
cmd/ztest/ztest.c
lib/libzfs/libzfs_pool.c
module/zcommon/zfs_namecheck.c
module/zfs/dmu.c
module/zfs/include/sys/dmu.h
module/zfs/include/sys/zfs_fuid.h
module/zfs/spa.c
module/zfs/vdev.c
module/zfs/zap_micro.c
module/zfs/zfs_fuid.c
module/zfs/zfs_ioctl.c
module/zfs/zfs_vfsops.c
module/zfs/zfs_znode.c
2009-07-06 13:40:29 -07:00
Brian Behlendorf
e2b2597751
Merge branch 'gcc-c90' into refs/top-bases/gcc-branch
...
Conflicts:
cmd/zdb/zdb_il.c
cmd/zfs/zfs_main.c
cmd/zinject/zinject.c
cmd/ztest/ztest.c
lib/libzfs/libzfs_dataset.c
lib/libzfs/libzfs_graph.c
module/zcommon/include/sys/fm/fs/zfs.h
module/zcommon/include/zfs_deleg.h
module/zcommon/include/zfs_namecheck.h
module/zcommon/zfs_deleg.c
module/zcommon/zfs_namecheck.c
module/zcommon/zprop_common.c
module/zfs/arc.c
module/zfs/dmu.c
module/zfs/dmu_object.c
module/zfs/dmu_objset.c
module/zfs/dsl_pool.c
module/zfs/dsl_prop.c
module/zfs/fletcher.c
module/zfs/include/sys/dsl_deleg.h
module/zfs/include/sys/dsl_prop.h
module/zfs/include/sys/metaslab_impl.h
module/zfs/include/sys/spa_boot.h
module/zfs/include/sys/zap.h
module/zfs/include/sys/zap_impl.h
module/zfs/include/sys/zfs_context.h
module/zfs/include/sys/zfs_ctldir.h
module/zfs/include/sys/zfs_dir.h
module/zfs/include/sys/zfs_fuid.h
module/zfs/include/sys/zfs_ioctl.h
module/zfs/spa.c
module/zfs/spa_errlog.c
module/zfs/spa_history.c
module/zfs/zap.c
module/zfs/zap_leaf.c
module/zfs/zap_micro.c
module/zfs/zfs_ioctl.c
module/zfs/zio.c
2009-07-02 16:49:11 -07:00
Brian Behlendorf
9babb37438
Rebase master to b117
2009-07-02 15:44:48 -07:00
Brian Behlendorf
77695eacc1
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
2009-03-12 10:02:45 -07:00
Brian Behlendorf
dcc25c44da
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
2009-03-12 10:00:48 -07:00
Brian Behlendorf
0cdc14e427
Merge branch 'linux-arc' into refs/top-bases/linux-zfs-branch
2009-03-12 10:00:07 -07:00
Brian Behlendorf
eceaf813ad
Merge branch 'gcc-missing-case' into refs/top-bases/gcc-branch
2009-03-12 10:00:01 -07:00
Brian Behlendorf
f2d72af596
Add remaining missing cases (or a default) to all switch statements.
...
The previous code was not wrong, but this prevents gcc from warning
us about missing cases for these known safe switch statements. The
-Wno-missing-cases can now be removed to detect places where we
accidentally forgot a case.
2009-03-12 09:53:08 -07:00
Brian Behlendorf
53b7082303
Merge branch 'linux-have-libefi' into refs/top-bases/linux-zfs-branch
2009-03-11 22:28:01 -07:00
Brian Behlendorf
426ed71564
Pull unused function under HAVE_LIBEFI ifdef.
2009-03-11 22:17:38 -07:00
Brian Behlendorf
b392fd33fd
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
2009-03-11 21:02:27 -07:00
Brian Behlendorf
9c4cc2ae78
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
2009-03-11 21:00:25 -07:00
Brian Behlendorf
c351352990
Merge branch 'linux-arc' into refs/top-bases/linux-zfs-branch
2009-03-11 20:59:46 -07:00
Brian Behlendorf
9915249546
Merge branch 'gcc-missing-braces' into refs/top-bases/gcc-branch
2009-03-11 20:53:11 -07:00
Brian Behlendorf
d4dbc7dca8
Resolve all instances of missing braces.
2009-03-11 20:52:21 -07:00
Brian Behlendorf
a6fbd61ff1
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
2009-02-18 15:23:07 -08:00
Brian Behlendorf
e77f9a10a9
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
2009-02-18 15:20:53 -08:00
Brian Behlendorf
e60db6f9dd
Merge branch 'linux-arc' into refs/top-bases/linux-zfs-branch
2009-02-18 15:20:14 -08:00
Brian Behlendorf
8c228734a3
Fix cast
2009-02-18 15:15:56 -08:00
Brian Behlendorf
437bc77985
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
2009-02-18 14:36:49 -08:00
Brian Behlendorf
f78c15d84f
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
2009-02-18 14:34:03 -08:00
Brian Behlendorf
8090a9a908
Merge branch 'linux-arc' into refs/top-bases/linux-zfs-branch
...
Conflicts:
cmd/zpool/zpool_main.c
2009-02-18 14:31:46 -08:00
Brian Behlendorf
e203e7b48f
Merge commit 'refs/top-bases/gcc-cast' into gcc-cast
2009-02-18 13:12:35 -08:00
Brian Behlendorf
f686a87058
Merge branch 'gcc-c90' into refs/top-bases/gcc-branch
...
Conflicts:
module/zfs/arc.c
2009-02-18 13:12:26 -08:00
Brian Behlendorf
d164b20935
Rebase master to b108
2009-02-18 12:51:31 -08:00
Brian Behlendorf
ca804c66f8
Merge branch 'linux-have-zvol' into refs/top-bases/linux-zfs-branch
2009-01-16 14:55:26 -08:00
Brian Behlendorf
7c5b7d2a94
This should always be success when zvol support is disabled
2009-01-16 14:52:35 -08:00
Brian Behlendorf
df7ad715a9
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
2009-01-15 14:21:49 -08:00
Brian Behlendorf
476261f2d5
Merge commit 'refs/top-bases/linux-have-zvol' into linux-have-zvol
2009-01-15 14:21:18 -08:00
Brian Behlendorf
cb8e50168e
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
2009-01-15 14:19:06 -08:00
Brian Behlendorf
1f372d9030
Resolve conflict with removed cleaner type
2009-01-15 14:18:01 -08:00
Brian Behlendorf
a2e601c6e3
Merge commit 'refs/top-bases/gcc-cast' into gcc-cast
2009-01-15 14:04:39 -08:00
Brian Behlendorf
3fa768e21b
Resolve conflict with removed cleaner type
2009-01-15 14:04:35 -08:00
Brian Behlendorf
fb5f0bc833
Rebase master to b105
2009-01-15 13:59:39 -08:00
Brian Behlendorf
7e43e16395
Merge branch 'linux-have-libefi' into refs/top-bases/linux-zfs-branch
2008-12-16 15:34:50 -08:00
Brian Behlendorf
35f607040f
Wrap additional new efi code in HAVE_LIBEFI macros
2008-12-16 15:33:00 -08:00
Brian Behlendorf
645c51287f
Merge commit 'refs/top-bases/linux-user-disk' into linux-user-disk
2008-12-11 11:37:35 -08:00
Brian Behlendorf
076f7c6a5f
Merge commit 'refs/top-bases/linux-have-zvol' into linux-have-zvol
2008-12-11 11:36:40 -08:00
Brian Behlendorf
1b0348e335
Merge commit 'refs/top-bases/linux-have-libefi' into linux-have-libefi
2008-12-11 11:35:29 -08:00
Brian Behlendorf
aca9d98817
Fix conflict
2008-12-11 11:34:16 -08:00