Skip to content

kernel_init: config_load, native: config_load: set id/address to PID#700

Merged
LudwigKnuepfer merged 2 commits intoRIOT-OS:masterfrom
LudwigKnuepfer:sniper_700
Mar 19, 2014
Merged

kernel_init: config_load, native: config_load: set id/address to PID#700
LudwigKnuepfer merged 2 commits intoRIOT-OS:masterfrom
LudwigKnuepfer:sniper_700

Conversation

@LudwigKnuepfer
Copy link
Copy Markdown
Member

  • set nativenet address and id to the host process' PID on config_load
  • call config_load in kernel_init

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-  * XXX: loading not implemented
+  * XXX: loading is implemented

Or just scrape the lines. :)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather leave it as the intention is to be able to load the whole configuration from file at some point.

@OlegHahm OlegHahm self-assigned this Feb 14, 2014
@kaspar030
Copy link
Copy Markdown
Contributor

nice snipe. gratulations for hitting #700!

@OlegHahm
Copy link
Copy Markdown
Member

Wouldn't it make more sense to always call config_load() when the config module is loaded (and not only with auto_init)?

@OlegHahm
Copy link
Copy Markdown
Member

/home/oleg/git/RIOT/examples/default/bin/native/native_base.a(board_config.o): In function `config_load':
board_config.c:(.text+0xe): undefined reference to `DEBUG'

I guess a debug.h include is missing.

@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

@OlegHahm Always call config_load() - from where?

@OlegHahm
Copy link
Copy Markdown
Member

Something like kernel_init()? I dunno.

LudwigKnuepfer pushed a commit to LudwigKnuepfer/RIOT that referenced this pull request Feb 24, 2014
LudwigKnuepfer pushed a commit to LudwigKnuepfer/RIOT that referenced this pull request Feb 24, 2014
also add include
addresses RIOT-OS#700 (comment)
LudwigKnuepfer pushed a commit to LudwigKnuepfer/RIOT that referenced this pull request Feb 24, 2014
@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

rebased and issues addressed

@OlegHahm
Copy link
Copy Markdown
Member

Since config_save isn't implemented I know get a weird address when using native with config module.

@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

If you mean PID with weird: that's half the idea of this PR.

@OlegHahm
Copy link
Copy Markdown
Member

Maybe I shouldn't comment on stuff I haven't looked into for weeks after midnight and comment on them...

@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

You are still lacking sleep.

@OlegHahm
Copy link
Copy Markdown
Member

Well, than ACK and go.

Sorry, one more mistake: core changes, need a second ACK then.

@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

Needs squashing.

@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

rebased and sqashed

@LudwigKnuepfer LudwigKnuepfer changed the title nativenet config_load, auto_init kernel_init: config_load, native: config_load: set id/address to PID Mar 18, 2014
@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

@mehlis @Kijewski you want to ACK something? Try this ;-)

@Kijewski
Copy link
Copy Markdown
Contributor

Quid pro quo? #859 has already one ACK.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a write-only variable?

@Kijewski
Copy link
Copy Markdown
Contributor

@OlegHahm Always call config_load() - from where?

Something like kernel_init()? I dunno.

Was this discussion finished?

@LudwigKnuepfer
Copy link
Copy Markdown
Member Author

I migrated the call, yes.

@Kijewski
Copy link
Copy Markdown
Contributor

Ah, now I see. I was confused by

 extern int main(void);
@@ -81,6 +88,11 @@ void kernel_init(void)

At first glance I though you used it in the project's main.

ACK.

LudwigKnuepfer pushed a commit that referenced this pull request Mar 19, 2014
kernel_init: config_load, native: config_load: set id/address to PID
@LudwigKnuepfer LudwigKnuepfer merged commit f490a70 into RIOT-OS:master Mar 19, 2014
@LudwigKnuepfer LudwigKnuepfer deleted the sniper_700 branch March 19, 2014 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Platform: native Platform: This PR/issue effects the native platform Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation Type: question The issue poses a question regarding usage of RIOT

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants