Vercas3 has quit [Remote host closed the connection]
chiselfuse has quit [Remote host closed the connection]
foudfou has quit [Remote host closed the connection]
Vercas3 has joined #osdev
foudfou has joined #osdev
chiselfuse has joined #osdev
netbsduser has joined #osdev
<klys_>
my adventures with ovmf over the last few days have left me in the lurch. no video from qemu after compiling it.
<klys_>
so when I first decided to compile it I had just got seabios done as Csm16.bin and the directions say to drop it into your ovmf tree.
<klys_>
after compiling the latest ovmf it became apparent that isn't part of their tree anymore, and Csm has been patched out of head.
<klys_>
the date on the patch is 2019, so I checked out a branch from 2018 called UDK2018
<klys_>
compiling that and UDK2017 were both fruitless due to a linker bug, and the best advice I found was to downgrade gcc to gcc-4.9
<klys_>
now it compiles and Csm16.bin appears to be firmly in place, and I have no video.
<klys_>
CSM2018 requires a few other things such as acpica-tools, libpython2.7-stdlib, and g++-4.9-multilib
<klys_>
gcc-4.9-multilib that is, except this package leaves my debian in an inconsistent state and I can't use apt in the meantime.
<klys_>
I am running trixie here
<klys_>
one of the convenient things about trixie is linux-libc-dev:all is not tied to an arch
Left_Turn has joined #osdev
<klys_>
another thing is when passing -kernel /boot/vmlinuz-* -append "root=/dev/sda2 console=ttyS0" -bios /usr/share/ovmf/OVMF.fd -nographic; to qemu, there is no serial output evident either.
Left_Turn has quit [Ping timeout: 264 seconds]
jtbx has left #osdev [#osdev]
Left_Turn has joined #osdev
Turn_Left has joined #osdev
Left_Turn has quit [Ping timeout: 268 seconds]
aktaboot has joined #osdev
aktaboot has quit [Remote host closed the connection]
xenos1984 has quit [Ping timeout: 246 seconds]
xenos1984 has joined #osdev
npc has joined #osdev
gsekulski has joined #osdev
xenos1984 has quit [Ping timeout: 268 seconds]
emm has joined #osdev
xenos1984 has joined #osdev
Ellenor has joined #osdev
npc has quit [Remote host closed the connection]
Ellenor has quit [Remote host closed the connection]
<mjg>
oh no /var/run/name_service_door
<mjg>
/var/run/name_service_door: door to nscd[214]
<netbsduser>
i call them "object descriptors" because this is the term used in a lot of venerable sources on unix after they began to represent more than just files (the 4.3bsd man page for dup for example)
<heat>
everything is a file
<GeDaMo>
Is the file in a cake? :|
<mcrod>
hi
<mjg>
have you seen what SOLARIS did with fd ahandling tho
<geist>
hi
<mjg>
:O
<mjg>
they get away without rcu
<mjg>
but it's the usual bsd-quality crap
<mjg>
they make sure to not free the fd table when resizing
<mjg>
so it is always legal to take a look
<mjg>
then they fine-grained lock around the lookup, so the struct file thing is again safe to access
<mjg>
this is basically horid af
<Ermine>
but fine-grained locks are less pessimal, arent they
<mjg>
mofo
<mjg>
that's for lookup
<mjg>
freebsd, netbsd and ofc linux do it lockless
<mjg>
while these poor saps slap in a lock trip around it
<mjg>
it does beat doing a lookup with one lock for all fds tho
<heat>
and onyx
<heat>
hi geist
<mjg>
you do lockless?
<mjg>
how?
<geist>
heat: sup
<heat>
rcu
<mjg>
you got rcu? :O
<mjg>
w00t
<mjg>
noice
navi has joined #osdev
<heat>
yes i have rcu m8
<heat>
we've talked about this before
alpha2023 has joined #osdev
<mjg>
i remembet you wanted to add it, don't recall going through with the thing
<netbsduser>
mjg: i read about the way solaris is doing it and it was certainly interesting
<mjg>
it is for "crap" values of interesting
<netbsduser>
ever since i got rcu i have gone sour on using more complicated locking strategies where much simpler strategies are possible with rcu
<geist>
hmm, did the write the rcu implementation from scratch?
<netbsduser>
and i understand matt dillon's point more and more
<netbsduser>
i wrote an rcu implementation directly from the thorough description in the patent (now expired)
<heat>
geist, i used some early RCU lwn articles and early patch descriptions
<heat>
this is the early, sane version of RCU that only scaled to hundreds of CPUs and not thousands
<geist>
cool. didn't know if that was easily possible or so
<netbsduser>
the first patent anyway - the newer ones for sleeping rcu, rcu with trees, and such are not expired
<heat>
early rcu is seriously not rocket science
<mjg>
ye
<mjg>
it's the core idea which matters
<mjg>
past that it's pretty pedestrian
<geist>
yah it was just patented, and thus completely off limits to me for so long
<netbsduser>
tree rcu is nice and when i understood the principle of it i liked it
<heat>
tree rcu, rcu modifications for idle, etc, are the complex shit
<netbsduser>
i will not share on tree rcu in case anyone doesn't want to hear patented stuff, but it is what it sounds like
<mjg>
for a real product the problem is you may infringe on another patent by accident
<mjg>
so
<heat>
i LGPL'd the code
<heat>
so no one can patent-fuck-me
<geist>
indeed, hence why i've generally stayed away from it
<mjg>
you would need some serious review to get things in
<mjg>
still
<mjg>
for the scale fuchsia is going to operate on you can probably implement that and reap all the benefits
<mjg>
which afair is always lower than smaller core count
<netbsduser>
yes, netbsd has pserialize which is in the same family, but they are afraid of doing rcu proper
<geist>
oh i'm not talking about fuchsia at all
<geist>
that's a different story
night has quit [Remote host closed the connection]
<heat>
get tha lawyerz
<geist>
i'm just talking about for hobby stuff or even just being interested in it
night has joined #osdev
<netbsduser>
exactly because they want to put clear blue water between themselves and the incredible parade of linux patents
<geist>
but have stayed away
<netbsduser>
and you can patent anything these days, it's ridiculous
<netbsduser>
microsoft has a patent for something called WaitOnAddress/WakeAddress, which is almost exactly the same as a futex
<mjg>
multicore patents are pretty ridiculous
<heat>
geist, to be fair, for lk it'd be pretty redundant
<geist>
indeed
<mjg>
most obvious shit out there is patented
<geist>
though i'm always looking for things to do, modernize, etc
<heat>
rcu has a real problem where it just churns memory temporarily
<netbsduser>
when i asked someone how on earth this could work, i was suggested that because it isn't cross-process, it's somehow a different thing
<netbsduser>
so my feeling is that the GNU people are right and that software patents really are an abomination
gsekulski has left #osdev [#osdev]
<nikolar>
They indeed are
<nikolar>
Thought that was obvious long ago
<zzo38>
I think that all patents are no good and should be abolished.
<heat>
netbsduser, how does pserialize work?
<heat>
oh there's a man page
Jari-- has quit [Ping timeout: 264 seconds]
<heat>
it is indeed very rcu-like, but i imagine it's not using QSBR
<netbsduser>
heat: it works on top of a mechanism called xcall
<netbsduser>
that's a way to request another cpu carry out a callback
<netbsduser>
the pserialise read sections call spl to raise priority to such a level as to inhibit xcall callbacks of the priority used by pserialise from running
<heat>
okay that is QSBR
<heat>
they're already stepping on the patents
<netbsduser>
the writers' interface is different however
<netbsduser>
there is no call_rcu
<netbsduser>
what you have to do instead is to call pserialialize_perform, a bit like synchronize_rcu, but pserialize_perform broadcasts an xcall to all cores
<netbsduser>
and once every core has completed the callback, then it returns, and you can proceed to delete
heat has quit [Read error: Connection reset by peer]
heat has joined #osdev
<heat>
hmmm yummy crash again
FreeFull has joined #osdev
<netbsduser>
so the fundamental different then is quiescent state detection is explicit and quite heavy, as you are doing this every time you would have used call_rcu or synchronize_rcu
Starfoxxes has quit [Remote host closed the connection]
<heat>
yeah that's some real crap for any path that has semi-frequent writes
gbowne1 has joined #osdev
MiningMarsh has quit [Ping timeout: 252 seconds]
MiningMarsh has joined #osdev
<netbsduser>
it is very heavy
dennis95 has quit [Quit: Leaving]
<Ermine>
Oh, thermald is not supported on my laptop...
<Mondenkind>
'every time' you can defer it, surely
<netbsduser>
i will admit i think i just learned how pserialise works just now
gbowne1 has quit [Remote host closed the connection]
<netbsduser>
let's see where they use it
gbowne1 has joined #osdev
<heat>
Mondenkind, it might be that deferring it is stepping over the RCU qsbr patents
<Mondenkind>
T_T
<Mondenkind>
'hey we patented queues, you're not allowed to put shit in queues now'
<heat>
"hey it's this thing where we stop you from running a bunch of callbacks for 'reclamation' during a read period, which is implemented by simply not allowing quiescent points at all, including preemption"
<netbsduser>
there is another mechanism appaerntly
<netbsduser>
psref
<netbsduser>
that one permits sleeping
<netbsduser>
so this is perhaps the netbsd answer to sleeping RCU
pieguy128 has quit [Ping timeout: 264 seconds]
<heat>
oh yeah preemptable RCU is also patented
pieguy128 has joined #osdev
heat has quit [Remote host closed the connection]
Bonstra_ has quit [Quit: Pouf c'est tout !]
heat has joined #osdev
heat has quit [Remote host closed the connection]
heat has joined #osdev
Cenkeden has quit [Quit: Leaving.]
Bonstra has joined #osdev
GeDaMo has quit [Quit: 0wt 0f v0w3ls.]
<nikolar>
Heat what rcu isn't patent encumbered
<heat>
the first one(s)
<heat>
but i didn't really check too deep cuz i didn't really care, LGPL 4 life
<heat>
but preemptible rcu is one of the later inventions, together with tree rcu and a bunch of fun ideas for idle
<nikolar>
But all ate fair game if use {l,}gpl
<nikolar>
*rcu
gsekulski has joined #osdev
<heat>
yep
gsekulski has left #osdev [#osdev]
<nikolapdp>
neato i was planning on using gplv3 anyway so no patent concerns there
<heat>
use v2
<heat>
v3 is baaaaad mkay
<Ermine>
^
<nikolapdp>
why's that
<nikolapdp>
genuinely curious
<heat>
because tivoization is normal, not all software needs to be exchangeable
<nikolapdp>
ah right, the word i forgor the meaning of
<nikolapdp>
(that forgor was a typo but i kept it :P )
<nikolapdp>
a
<heat>
for example, apple can't update bash to a modern version because gplv3 won't let it have a read-only system software partition
<nikolapdp>
so what's the exact reason that was added then
<nikolapdp>
because in that case it sounds like a silly thin
<zid>
НЯ
<heat>
because they strongly think tivoization is bad and everyone should be able to replace their software
<nikolapdp>
what exactly is tivoization
<Ermine>
it would be desirable tbh
<nikolapdp>
i mean it's my silly os, i don't think anyone would care if it's gplv3 instead of gplv2
<heat>
tivoization comes from tivo (the tv provider) using linux but not allowing you to replace the software
<heat>
then GNU/FSF got really mad
<zid>
nikolapdp: tivoization is making something 'for free' by using all gplv2 software, but then adding drm/etc to stop anybody actually modifying the device
<netbsduser>
that's what their goal was
<nikolapdp>
doesn't sound like a that bad thing to me
<zid>
it's not hugely a problem, but, tivo took the piss
<zid>
and made a small problem
<netbsduser>
they didn't invent the GPL so that people could inscribe source code onto crystal vessels to look at it, but for the practical purpose of trying to let people replace software and such
<Ermine>
your firmware consists of free software, but effectively you can't excercise your rights
<zid>
It's an end-run around your rights, yea
<nikolapdp>
right yeah, so tivoization clause isn't that bad (tm)
<netbsduser>
as the story goes maurice stallman invented the GNU after he was told he couldn't replace a printer's firmware
<netbsduser>
matthew, whatever he's called now
<zid>
how does android deal with it I wonder
<heat>
the problem is that not all software should be replaceable
<zid>
just by.. the software authors not being the phone authors?
<heat>
say i buy a phone, replace the kernel with a compromised one that's spying on you, then sell it to you
<heat>
oopsie!
<nikolapdp>
heat well it's my os and i say it should be replacable because it's going to be crap :P
<heat>
lol
<zid>
so if the phone designers only accept signed firmware blobs from certain vendors, who then use a bunch of gnu, nobody can figure out who to complain to?
<netbsduser>
the gnu principle is that it all should be
<Ermine>
that can be said about any tech seller
<netbsduser>
and i think this is why some people invented the term "open source" instead
<Ermine>
(and here in .ru shelves already full of phones containing spyware)
<netbsduser>
because those people just like looking at source code and maybe stealing it for their own products but they don't care about actually doing anything else with it
<nikolapdp>
v3 for the win then
<heat>
what
<Ermine>
me, being paranoic: flashes another firmware
<heat>
that makes sense
<heat>
but, say, if samsung nails their crypto and secure bootieness, no mitm will be able to replace their stuff
<Ermine>
that said, it is legal to release nonfree kernel modules, so irl there's no 'another firmware'
<heat>
it's overall safer
<zid>
kernel is v2 anyway
<Ermine>
s/samsung/android, all of them have verified boot
<Ermine>
sadly, working verified boot and replaceable firmware are incompatible
rustyy has quit [Ping timeout: 252 seconds]
<heat>
this is exactly why secure boot exists, but the open-source paranoid people think it's about microsoft taking away their guns
<heat>
i mean taking away their linux
<Ermine>
I mean how secure boot is made on android phones
<heat>
i know
<nikolapdp>
who issues the secure boot certs
<Ermine>
Certs there are irreplaceable afaik, unless a small number of phones implementing user-set root of trust, and those phones are mostly Pixels
<heat>
trusted entities
<nikolapdp>
and who are these "trusted" entities
<zid>
It'sme
<heat>
commonly it's microsoft, but microsoft signed a bunch of other certs
<heat>
so red hat, canonical can all sign their kernels
<Ermine>
on PCs, certs are replaceable, and microsoft even demands that to give their holographic stickers, certification 'n shit
<Ermine>
(And I've even installed my own certificates)
<Ermine>
Actually, idk how root of trust is stored on android phones. Is it some kind of memory that just can't be overwritten because physics disallow that? Never heard of such kinds of memory
<zid>
you've never heard of rom?
<zid>
most game console security is implemented by internal roms
<heat>
the way it works in PCs is that they store the key in fuses
<heat>
then that starts the chain of trust
<zid>
the cpu or gpu or something just has a boot rom inside it, advertized on the bus at startup, then eventually once it's done verifying the 2nd stage bootloader off the volatile storage (nand, hard drive, whatever) it does a magic poke that drops itself from the bus
<zid>
and execution continues from there
Cenkeden has joined #osdev
<Ermine>
oh, fuses. If stuff was modified you at least can know it
<zid>
xbox security was weird, they had a virtual machine in the boot rom, and boot2 was just bytecode for that virtual machine
<zid>
guess they couldn't fit the full verification routine in the mask rom
<zid>
they banned the bytecode from writing the mask rom disable word, but fucked up and forgot about address mirroring, so you can do it anyway :P
<nikolapdp>
lel
<zid>
they also forgor that memory wraps around (or remembered and forgot they changed between amd and intel mid project, unsure) so you can just run eip off the end of memory and execute ram at 0x0
<zid>
as only jumps inside the top of memory are supposed to be valid inside the bytecode, to stop you escaping
<nikolar>
very nice
<zid>
gameboy just maps the boot rom over 0x0 and then the final thing it does at PC=0xFF is disable itself, and the game cart is also mapped from 0x0, so games just execute from 0x100
Cenkeden has left #osdev [#osdev]
<Ermine>
but anyway, gplv3 doesn't help
netbsduser has quit [Ping timeout: 255 seconds]
<heat>
proprietary modulen momenten
<zzo38>
On Game Boy, the header is stored at 0x100 and the header usually starts with an instruction to jump to the proper starting address; the boot ROM also reads the header to determine if it is colours or mono and to verify that it is a valid Game Boy cartridge (by a checksum and a Nintendo logo); emulators can use the other information in the header for additional functions.
<Ermine>
yes, also hw docen
<zzo38>
I dislike the way the secure boot and UEFI is working, because I think they are too complicated for that function and has other problems too.
* Ermine
wants to replace home smart tv firmware
<zzo38>
I don't want smart TV. Older TV sets would not need a operating system and this one shouldn't need either. Additional functions can be added by external devices such as a VCR; the functions to add into the TV set itself might include picture setting, input selection, and perhaps audio volume (if you do not want to use external speakers with their own volume controls)
<heat>
>a VCR
<heat>
found the 1980s time traveller
<zzo38>
Or a VCR/DVD combo
<Ermine>
because webdevOS on a weak mips cpu is visibly sluggish
<Ermine>
and it literally runs out of memory
spare has quit [Remote host closed the connection]