IRC channel logs

2020-04-24.log

back to list of logs

<damo22>almuhs: hi
<almuhs>hi
<damo22>i have some time off work and i can work on hurd
<almuhs>I found the docs of acpica
<damo22>last night i almost got acpica compiled into gnumach, there are some errors currently
<almuhs>in the reference there are the docs of APIC functions
<almuhs>in linux, I had to install bison and flex
<almuhs>to compile acpica
<damo22>ok
<almuhs>at very first, I can test the functions in linux.
<damo22>yes
<almuhs>but I have doubts, because the docs don't explain what library I have to include
<almuhs>#include ... what?
<damo22>#include <linux/acpi.h>
<almuhs>oh, ok
<damo22>thats all i think
<almuhs>then I will try AcpiGetTable() function
<damo22>but are you using the get-repo.sh
<damo22>to filter the code to linuxized version?
<almuhs>I installed It using make
<almuhs>make && sudo make install
<damo22>dont use the upstream plain version
<damo22>its hard to read
<almuhs>then... have I to install this from repositories?
<damo22>you clone the upstream code, but you run a filter program
<damo22>it generates a new repo for you
<almuhs>oh, ok
<almuhs>I simply compiled the code
<damo22>./generate/linux/gen-repo.sh
<almuhs>ok
<damo22>just run that in the root git folder
<almuhs>done
<damo22>it will create linux-HASH/repo
<damo22>and you can use the code from in there
<damo22>there is an example tool as well
<damo22>that calls acpi functions
<damo22>i will push what ive got so far
<damo22>its still broken but the tree is there
<almuhs>I put the test file into the root acpica directory
<almuhs>?
<damo22>once it generates the code you only need what is inside linux-HASH
<damo22>the rest is useless
<almuhs>what have I to do with the contents of linux-HASH ?
<damo22>should be drivers/ include/ tools/
<almuhs>yes, It is
<damo22>try to compile the tool
<damo22>in tools/
<damo22>it will probably use your linux kernel headers
<damo22>instead of drivers/ and include/
<damo22>im not sure
<almuhs>ok
<damo22> http://git.zammit.org/gnumach-sv.git/log/?h=debian-acpica
<damo22>this almost compiles, im working on it now
<almuhs>the next step is add this inside gnumach, is not?
<damo22>it will create libacpica.a
<damo22>yes that is what i have done
<almuhs>oh, ok
<damo22>have a look at the commits
<almuhs>then, now It's necessary to create a interface between gnumach and this library
<almuhs>I'm checking the commits
<almuhs>this seems good
<damo22>there is already an interface you just #include <acpi/acpi.h> i think
<damo22>and link to libacpica.a
<damo22>but its still not compiling yet
<almuhs>then, this is the next step
<almuhs>#include <linux/acpi.h> not compiles
<almuhs>in linux
<damo22>try <acpi/acpi.h>
<almuhs>neither
<almuhs>Have I to add any flag to GCC for this?
<almuhs>I'm simply doing "gcc acpica_test.c -o acpica_test"
<damo22>have a look in linux-HASH/tools
<damo22>there should be a test program
<damo22>im getting multiple redefinition of symbols
<damo22>in my gnumach
<damo22>i need to add some special macros
***Server sets mode: +nt
<almuhs>but this doesn't works for me
<damo22>maybe its supposed to be built as part of a linux kernel
<damo22>have a look at the makefile
<almuhs>in linux-HASH there are not a makefile
<almuhs>maybe do I need to download the linux sources?
<damo22>AHAHA It compiled
<damo22>and linked!!
<almuhs>:D
<damo22>-rw-r--r-- 1 demo demo 7908364 Apr 24 09:40 libacpica.a
<almuhs>congrats
<damo22>and gnumach linked
<almuhs>:-)
<almuhs>now try to boot with this microkernel, to check that this doesn't crash
<damo22>theres a few warnings
<damo22>compiler
<almuhs>there are some warning during compilation
<almuhs>is not?
<damo22>yep
<damo22>theres also a couple of things i hacked to make it compile
<damo22>but only in the config
<damo22>eg spinlock_t and kmem_cache
<damo22>i dont know what they should be
<damo22>kernel boots
<almuhs>ok
<almuhs>do some tests with It and, if you want, send a patch to gnumach's upstream
<almuhs>or you prefer to test It with acpi tables before?
<damo22>i need to remove some warnings and figure out what the missing structs are for
<damo22>i should probably make it init the tables too
<damo22>and store them in a static variable
<almuhs>It's fine
<almuhs>but the current work is a good work, anyway
<damo22>:)
<almuhs>I need to go sleep, It's so late and I'm exhausted
<damo22>ok
<almuhs>write me to the maillist if you want notice me any news
<damo22>yeah
<damo22>goodnight!
<almuhs>bye, and thanks
<damo22>woot most warnings gone
<damo22>and i did it with just glue code, didnt touch the sources
<damo22>acpica is linked into gnumach and theres no missing symbols
<damo22>\o/
<damo22>how do i call a function without getting duplicate symbols?
<damo22>its failing at link time when i try to call acpi_initialize_tables()
<damo22>i can compile in the acpica but when i try to use any of the functions in a new c file, i get every symbol duplicated
<damo22>ok i figured it out i need to implement some empty stubs
***dp is now known as DP
***DP is now known as dp
<damo22>youpi: hey, ive almost added acpica to gnumach
<damo22>im missing these symbols isdigit isprint isspace isxdigit tolower toupper vsprintf
<damo22>heh it linked
<damo22>youpi: how do i get stuff to print in the kernel log?
<damo22>it boots
<damo22>but i cant read the log
<damo22>ie, i want it to appear in /var/log/dmesg
<damo22> http://git.zammit.org/gnumach-sv.git/log/?h=debian-acpica
<damo22>it boots
***rekado_ is now known as rekado
<gnu_srs1>damo22: Nice work :)