Skip to content
This repository has been archived by the owner on Aug 2, 2018. It is now read-only.

Parameters configured from static variables forced to 1 #10

Open
vmayoral opened this issue Sep 30, 2014 · 3 comments
Open

Parameters configured from static variables forced to 1 #10

vmayoral opened this issue Sep 30, 2014 · 3 comments

Comments

@vmayoral
Copy link
Member

Parameters are set to be invalid. Why does this happen. If this line is removed or the code forces parameters to have valid values (e.g. here) the code crashes at locator_pool_init.

Because !locrefs->reserved and !locators->reserved are 1:

nsh> dds_chat
Network configured, starting DDS chat:
List pools created.
String pool initialized.
Typecode pools created.
Typesupport inAssertion failed at file:mm_free.c line: 137
sp:         10003090
stack base: 10003750
stack size: 000007e4
10003080: 10003080 10003080 100030a0 00000000 00000000 00000000 100030a0 08001c5b
100030a0: 10003090 10002b00 000007e4 10003750 100030b8 08001cd9 00000089 080a3a50
100030c0: 100030c8 08006f37 10003780 2000e068 10002f68 1000fff8 1000fff8 10003778
100030e0: 100030e8 08006ac3 00000004 10003780 100030f8 08067537 00000000 10003788
10003100: 200003dc 10003780 10003110 08022cc7 00000002 100037a8 2000044c 00000008
10003120: 00000000 0000000d 10003130 080233e9 10003138 08020f75 10003140 08013935
10003140: 10003148 08004303 080ac678 10002b00 0809f3e9 10002bd0 10003160 080043c9
10003160: 10002cac 00000012 00000001 10002b00 10003178 080034ed 10003190 00000001
10003180: 080ac678 10002b00 10003190 08068a2b 100031fc 080ac6e0 00000082 04040000
100031a0: 100031a8 0009f37d 00000000 00000100 100031fc 00000000 100031c0 0809e3cd
100031c0: 1000330c 080a5fd8 00000100 100031fc 0809e3d9 08006255 00000025 100031fc
100031e0: 000000ff 00000000 100031f8 0806922d 00000001 10003204 00000000 61636f6c
10003200: 5f726f74 6c6f6f70 696e695f 20292874 6c696166 203a6465 6f727265 203d2072
10003220: 00000034 10003228 00000061 20000000 2000e068 20000000 10003240 08002741
10003240: 00000a00 20000000 00000000 0004083c 0000000c 40020c00 00000003 10000000
10003260: 00003268 10003268 10003270 00000000 100032b0 3b9aca00 00000000 0ee6b280
10003280: 00000000 0ee6b280 00000000 100032b0 00000000 0ee6b280 00000008 0000203a
100032a0: 00000000 100032a8 100032d0 00000000 0674c008 0ee6b280 00000000 00000000
100032c0: 100032c8 0806831d b98eb46d 10002b00 0674c008 100032d8 100032e0 600434df
100032e0: 0674c008 100032e8 100032f8 600434df 100032f8 0801ca17 10003538 1000330c
10003300: 10003320 08014765 080a5fd8 00000004 1000336c 00000004 00000000 00000000
10003320: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003340: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003360: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003380: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000065
100033a0: 00000000 20000000 00000000 100033b0 00000065 20000000 00000000 20000000
100033c0: 100033c8 08002741 00000000 20000000 00000000 0004083c 0000000c 40020c00
100033e0: 00000003 10000000 0000ddd8 100033f0 100033f8 00000000 10003400 0800291b
10003400: 10003408 00000010 10003410 0800299f 10003418 00000004 10003420 080015a1
10003420: 10003438 00000036 10003430 00000000 10003498 0800047f 10003480 00000000
10003440: 00000000 00000000 00000000 10003498 00000000 00000000 00000000 00000000
10003460: 20000000 00000000 000000a2 00000000 00000000 08002741 08001356 01000000
10003480: 0100000a 2000000c 00003490 00000000 00000000 00000000 100034a0 0800217b
100034a0: 100034f0 00000000 10002ef7 10002c14 00000000 010a0000 20000000 10000070
100034c0: 00000000 00000027 100034d0 080983ef 00000000 00000027 10002ed0 00000001
100034e0: 00000000 00000027 10000070 10002c14 10002c00 10002b00 10003500 10003500
10003500: 10003508 10002cac 10002ed0 10002b00 10003518 10003518 00000034 10003564
10003520: 10003528 080052f5 00000004 10003564 00000034 100035e8 00000001 00000000
10003540: 00000000 00002000 00000001 00000000 00000000 00001000 00000001 00000000
10003560: 00000000 00000800 00000001 00000000 00000000 00000400 00000001 00000000
10003580: 00000000 00000200 00000001 00000000 00000000 00000100 00000001 00000000
100035a0: 00000000 00000080 00000001 00000000 00000000 00000040 00000000 00000000
100035c0: 20005164 00000004 20004934 00004000 0000000c 10003528 100035e0 08048045
100035e0: 0000f3e9 00000000 00000000 00000000 10003754 00000001 7ffffffe 00000006
10003600: 10003620 00000001 00000000 00000000 10003620 08011039 00000000 00000000
10003620: 10003754 00000001 00ffffff 00000000 00000000 00000000 00000000 00000000
10003640: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003660: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003680: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
100036a0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
100036c0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
100036e0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003700: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
10003720: 00000000 00000000 00000000 00000000 10003738 0800348f 00000000 00000000
10003740: 10002b00 00000001 00000000 00000000 00000000 1000375c 00000000 6e6f6e3c
up_hardfault: PANIC!!! Hard fault: 40000000
Assertion failed at file:armv7-m/up_hardfault.c line: 183
sp:         10002f48
stack base: 10003750
stack size: 000007e4
ERROR: Stack pointer is not within the allocated stack
R0: 00000004 10009b90 10009b88 0fffb6c8 00000000 00000000 00000000 10003018
R8: 00000000 00000000 00000000 00000000 000007ff 10003018 08006ce9 08006f1a
xPSR: 81000000 PRIMASK: 00000000 CONTROL: 00000000

@vmayoral
Copy link
Member Author

vmayoral commented Oct 1, 2014

Incrementing the stack of NuttX didn't help

@vmayoral
Copy link
Member Author

vmayoral commented Oct 7, 2014

An alternative to force them to be valid is to retrieve them no matter whether they have the valid bit field activated or not (in NuttX).

@vmayoral
Copy link
Member Author

vmayoral commented Nov 3, 2014

Tried again uncommenting these lines:

Network configured, starting DDS chat:
List pools created.
String pool initialized.
Typecode pools created.
Typesupport initialized.
Socket handler initialized.
Timer pool initialized.
Data buffer pools created.
Random host identifier generated.
Unique GUID prefix created: 380134d9:00000002:00060000
locator_pool_init() failed: error = 4
Exiting program!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant