diff options
author | Sander Vrijders <sander.vrijders@ugent.be> | 2017-05-15 16:25:08 +0000 |
---|---|---|
committer | dimitri staessens <dimitri.staessens@ugent.be> | 2017-05-15 16:25:08 +0000 |
commit | 1b3079ce9ad79e9c9b267fde3d09b9c8166ed1e5 (patch) | |
tree | ea57e4a1e634d3b7e7325b61f6dba36d941e03ae /src/ipcpd/normal/main.c | |
parent | 0fc0f3701ef4f504e71eadcc92a93faf1dd33bf4 (diff) | |
parent | 5d87cec1757c4e1c23ae778f2814363c1e39b43c (diff) | |
download | ouroboros-1b3079ce9ad79e9c9b267fde3d09b9c8166ed1e5.tar.gz ouroboros-1b3079ce9ad79e9c9b267fde3d09b9c8166ed1e5.zip |
Merged in sandervrijders/ouroboros/be-routing-policy (pull request #506)
ipcpd: normal: Make routing a policy
Diffstat (limited to 'src/ipcpd/normal/main.c')
-rw-r--r-- | src/ipcpd/normal/main.c | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/ipcpd/normal/main.c b/src/ipcpd/normal/main.c index f9718041..0b8a26ab 100644 --- a/src/ipcpd/normal/main.c +++ b/src/ipcpd/normal/main.c @@ -88,7 +88,7 @@ static int boot_components(void) log_dbg("Starting components."); - if (rib_read(BOOT_PATH "/addr_auth/type", &pa, sizeof(pa)) + if (rib_read(BOOT_PATH "/dt/addr_auth/type", &pa, sizeof(pa)) != sizeof(pa)) { log_err("Failed to read policy for address authority."); goto fail_addr_auth; @@ -261,17 +261,17 @@ const struct ros { {BOOT_PATH "/dt/const", "addr_size"}, {BOOT_PATH "/dt/const", "fd_size"}, {BOOT_PATH "/dt/const", "has_ttl"}, + {BOOT_PATH "/dt", "addr_auth"}, + {BOOT_PATH "/dt/addr_auth", "type"}, + {BOOT_PATH "/dt", "routing"}, + {BOOT_PATH "/dt/routing", "type"}, /* RIB MGR COMPONENT */ {BOOT_PATH, "rm"}, - {BOOT_PATH "/rm","gam"}, {BOOT_PATH "/rm/gam", "type"}, {BOOT_PATH "/rm/gam", "cacep"}, - /* ADDR AUTH COMPONENT */ - {BOOT_PATH, "addr_auth"}, - {BOOT_PATH "/addr_auth", "type"}, {NULL, NULL} }; @@ -327,9 +327,12 @@ static int normal_ipcp_bootstrap(const struct ipcp_config * conf) rib_write(BOOT_PATH "/rm/gam/type", &conf->rm_gam_type, sizeof(conf->rm_gam_type)) || - rib_write(BOOT_PATH "/addr_auth/type", + rib_write(BOOT_PATH "/dt/addr_auth/type", &conf->addr_auth_type, - sizeof(conf->addr_auth_type))) { + sizeof(conf->addr_auth_type)) || + rib_write(BOOT_PATH "/dt/routing/type", + &conf->routing_type, + sizeof(conf->routing_type))) { log_err("Failed to write boot info to RIB."); return -1; } |