@@ -49,6 +49,9 @@ This is necessary to enable the pseudo-Ceph-device. Note that it's not a
real device but just a synonym to tell the kernel to use Ceph instead of
a real device.
+If cephroot is not specified, it is expected that that a valid mount will be
+found via DHCP option 17, Root Path [1]
+
cephroot=<monaddr>:/[<subdir>],<ceph-opts>
<monaddr> Monitor address. Each takes the form host[:port]. If the port
@@ -64,6 +67,7 @@ cephroot=<monaddr>:/[<subdir>],<ceph-opts>
4.) References
----------
+[1] http://tools.ietf.org/html/rfc2132
5.) Credits
-------
@@ -37,9 +37,6 @@ static char ceph_root_options[256] __initdata;
/* server:path string passed to mount */
static char ceph_root_device[MAXPATHLEN + 1] __initdata;
-/* Address of CEPH server */
-static __be32 root_ceph_server_addr = htonl(INADDR_NONE);
-
/*
* Parse out root export path and mount options from
* passed-in string @incoming.
@@ -97,7 +94,7 @@ static int __init ceph_root_setup(char *line)
* Note: root_nfs_parse_addr() removes the server-ip from
* ceph_root_params, if it exists.
*/
- root_ceph_server_addr = root_nfs_parse_addr(ceph_root_params);
+ root_server_addr = root_nfs_parse_addr(ceph_root_params);
return 1;
}
@@ -120,7 +117,7 @@ int __init ceph_root_data(char **root_device, char **root_data)
int len;
int ret = -E2BIG;
- servaddr = root_ceph_server_addr;
+ servaddr = root_server_addr;
if (servaddr == htonl(INADDR_NONE))
return -ENOENT;
@@ -128,6 +125,11 @@ int __init ceph_root_data(char **root_device, char **root_data)
if (tmp == NULL)
return -ENOMEM;
+ if (root_server_path[0] != '\0') {
+ if (root_ceph_parse_options(root_server_path, tmp, tmplen))
+ goto out;
+ }
+
if (ceph_root_params[0] != '\0') {
if (root_ceph_parse_options(ceph_root_params, tmp, tmplen))
goto out;
@@ -1435,10 +1435,10 @@ static int __init ip_auto_config(void)
* missing values.
*/
if (ic_myaddr == NONE ||
-#ifdef CONFIG_ROOT_NFS
+#if defined(CONFIG_ROOT_NFS) || defined(CONFIG_ROOT_CEPH)
(root_server_addr == NONE &&
ic_servaddr == NONE &&
- ROOT_DEV == Root_NFS) ||
+ (ROOT_DEV == Root_NFS || ROOT_DEV == Root_CEPH)) ||
#endif
ic_first_dev->next) {
#ifdef IPCONFIG_DYNAMIC
@@ -1465,6 +1465,12 @@ static int __init ip_auto_config(void)
goto try_try_again;
}
#endif
+#ifdef CONFIG_ROOT_CEPH
+ if (ROOT_DEV == Root_CEPH) {
+ pr_err("IP-Config: Retrying forever (CEPH root)...\n");
+ goto try_try_again;
+ }
+#endif
if (--retries) {
pr_err("IP-Config: Reopening network devices...\n");