klange changed the topic of #osdev to: Operating System Development || Don't ask to ask---just ask! || For 3+ LoC, use a pastebin (for example https://gist.github.com/) || Stats + Old logs: http://osdev-logs.qzx.com New Logs: https://libera.irclog.whitequark.org/osdev || Visit https://wiki.osdev.org and https://forum.osdev.org || Books: https://wiki.osdev.org/Books
PapaFrog has quit [Quit: ZNC 1.8.2+deb2 - https://znc.in]
PapaFrog has joined #osdev
gildasio has quit [Remote host closed the connection]
gildasio has joined #osdev
CalculusCat is now known as Calculuscats
Calculuscats is now known as CalculusCats
slidercrank has quit [Ping timeout: 250 seconds]
<mcrod> hi
<zid> we've already got one thanks
<heat> hi
<moon-child> not much, what's hi with you?
<heat> updog
<moon-child> updog deez nuts
<zid> what's deez updog
<heat> sugondese
goliath has quit [Quit: SIGSEGV]
nyah has quit [Quit: leaving]
PapaFrog has quit [Quit: ZNC 1.8.2+deb2 - https://znc.in]
PapaFrog has joined #osdev
josuedhg has quit [Quit: Lost terminal]
gildasio has quit [Remote host closed the connection]
Vercas has quit [Remote host closed the connection]
Vercas3 has joined #osdev
gildasio has joined #osdev
heat has quit [Read error: Connection reset by peer]
heat_ has joined #osdev
dude12312414 has joined #osdev
heat_ has quit [Remote host closed the connection]
heat_ has joined #osdev
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
Burgundy has joined #osdev
radens has joined #osdev
<radens> Hello. On an arm64 kernel, if the currently running process exits and there are not enough processes for the current core to be busy, it seems like a bad idea for ttbr0_el1 to point to a freed page table. I think I should disable translation and set ttbr0_el1 to a safe value. What is the recommended way to do this? Is it to set TCR_EL1.T0SZ to something invalid, or is there a better way to accomplish this?
<radens> Bonus points if someone knows the answer to the same question on x86_64 too
<klange> Do you have an idle task to schedule? You could allocate a user directory for it and just not treat it any different than a real process.
<Mutabah> have an idle process with its own paging structure
<radens> Right now I have a little asm loop in the kernel which enables interrupts, does a wfi, and loops again. Somehow having a whole process with a whole paging structure just for sitting around doing nothing seems wasteful
PapaFrog has quit [Quit: ZNC 1.8.2+deb2 - https://znc.in]
PapaFrog has joined #osdev
<zid> so don't
<zid> either you have the special case and no idle process, or you have no special case and an idle process
Burgundy has quit [Ping timeout: 240 seconds]
<geist> radens: it's probably a good idea. i did exactly that in zircon
<Mutabah> an empty paging structure is pretty cheap, just one page really
<geist> yeah but on arm64 you can just turn it off
<Mutabah> I use that process for kernel worker threads actually
frkazoid333 has quit [Read error: Connection reset by peer]
<bslsk05> ​fuchsia.googlesource.com: zircon/kernel/arch/arm64/mmu.cc - fuchsia - Git at Google
<geist> basically if switching to a pure kernel thread (idle included) it just turns off the bottom part. even reloads ttbr0_el1 with 0, though that's not strictly needed
<geist> figured it would be a good idea. also loads ASID 0 which is defined as being unused, and thus cannot alias anything
<geist> re disabling it there's a enable bit in the TCR for both halves, i forget what it is
frkazoid333 has joined #osdev
<geist> A1 bit?
<bslsk05> ​fuchsia.googlesource.com: zircon/kernel/arch/arm64/include/arch/arm64/mmu.h - fuchsia - Git at Google
<geist> been a while since it typed all that in, but the difference in flags between TCR_FLAGS_KERNEL and TCR_FLAGS_USER is that it disables user space
<geist> EPD0 maybe?
<zid> I need a better cpu, vampire surviors has frame drops
<zid> or maybe I figure out how the bizzare overclocking works on amd
kof123 has joined #osdev
jeaye has quit [Remote host closed the connection]
heat_ has quit [Remote host closed the connection]
heat has joined #osdev
<zid> I need more ideas for dumb things to do to my little gameboy program
<moon-child> mine bitcoins!
<zid> been done
<zid> also a lot of work for not a lot of output
<zid> current program does a lot of work in like.. 8 lines :p
bgs has joined #osdev
<kof123> you mean the emulator or you wrote a rom? does it support the multi-link thing (there was a racing game that was 4 or maybe 5-player IIRC? may be misremembering)
slidercrank has joined #osdev
<kof123> TLDR 4-5 bitcoin miners
crankslider has joined #osdev
crankslider has quit [Remote host closed the connection]
jeaye has joined #osdev
danilogondolfo has joined #osdev
heat_ has joined #osdev
heat has quit [Read error: Connection reset by peer]
xvmt has quit [Remote host closed the connection]
xvmt has joined #osdev
jeaye has quit [Ping timeout: 256 seconds]
nur has quit [Remote host closed the connection]
nur has joined #osdev
xenos1984 has quit [Read error: Connection reset by peer]
Burgundy has joined #osdev
nur has quit [Remote host closed the connection]
xenos1984 has joined #osdev
heat_ has quit [Remote host closed the connection]
heat_ has joined #osdev
dayimproper has joined #osdev
bgs has quit [Remote host closed the connection]
GeDaMo has joined #osdev
nyah has joined #osdev
<zid> http://skanthak.homepage.t-online.de/gcc.html mjg did you make this webpage
<bslsk05> ​skanthak.homepage.t-online.de: Deficiencies in GCC’s Code Generator and Optimiser
<sham1> It's pretty
<zid> It is pretty, it's also what we're busy laughing at in a different channel
<zid> but it says the word pessimal so I figured out who wrote it
<bslsk05> ​twitter: <stephentyrone> @johnregehr jokes on you, there are no optimized numerical libraries, because that one guy on llvm-dev can find an extra instruction in all of 'em.
<zid> can't see who that person is rizzing :(
gog has joined #osdev
<moon-child> 'the conditional branch impairs performance' workload dependent you asshat
<kof123> eh, his license is good. non-commerical current version only. so ...have to marry his website and track updates
<kof123> i suspect odds someone will actually bump into this code: <crickets> <tumbleweed> <raven crows> <wolf howls> <vulture pecks at corpse> <...>
* gog appears
<zid> (99% of those are "I don't understand how -march works")
* moon-child pets gog
<sham1> Unsolicited petting detected!
<Clockface> this kind of reminds me of an experiment i did once
<kof123> i suspect they may add up, don't know how often such things are called. just...gcc..will never take such code
<Clockface> for some reason adding 1 to a register until it overflows is like 1 or 2 percent faster than subtracting 1 on 0
<Clockface> for a loop that does nothing
<Clockface> on my computer
<Clockface> *1 until it hits 0
* gog prr
wootehfoot has joined #osdev
<Clockface> GCC was doing the style where it was subtracting 1 from a register until it set the 0 flag
<Clockface> i did the thing where it added to a register until overflow
<Clockface> and it was slightly faster
<Clockface> i averaged the results in a spreadsheet
<Clockface> so that was weird
<Clockface> the program just looped a billion times, for context
<Clockface> first program loaded RAX with 1 billion and subtracted until 0, second set all bits in RAX to high, and then add 1 to it until it overflowed
<Clockface> second was slightly slightly faster
<Clockface> on average
<Clockface> i dont know anything about why it would work that way
<gog> uh
<gog> you set all bits in rax to high
<gog> and then add 1
<gog> once
<gog> that's overflow
<gog> wait
<gog> sorry
<gog> i'm still drunk
<zid> typical icelander
<zid> drunk on a friday morning
<gog> i made it to work on time
<moon-child> maybe meant just set the high 34 bits to 1?
<sham1> Typiskt daydrinking
<gog> why 34 bits
<moon-child> cus 2^30 is a billion
<gog> no it isn't
<zid> 2^30 = 1 billion is good enough for the girls I go out with
<gog> :(
<moon-child> 10^9 is the poor man's billion
<zid> what's a few inches between best buddies
<Clockface> if i remember right i think i had it at 0 first then subtracted 1
<Clockface> because it was the least typing
<Clockface> and then it went to the subtract 1 billion and loop bit
<FireFly> they call it a _bi_llion because it's a binary kind of -illion, y'see,
<gog> nonbinaryillion
<gog> genderqueerillion
<moon-child> panillion
<Clockface> sexillion
<gog> y'all i've been here for like an hour and i haven't done any work lmao
<FireFly> quillion (queer billion)
<FireFly> gog: time to not do any work until lunch
<sham1> Get on my level. I've been here since 8 o'clock and I haven't gotten work done (it's 13 o'clock)
<sham1> The Friday effect
<FireFly> my old workplace (which was also a webdev kinda place) used to bring out the alcohol fridays at 15
<FireFly> pity I don't drink I guess
<gog> most of the office is here today tho, i'm shocked
<gog> we had a party last night and everybody drank hard
<Clockface> you have office parties good enough to get hangovers from?
<gog> hell yeah
dayimproper has quit [Ping timeout: 246 seconds]
<zid> discord pls stop shitting bed
<Ermine> gog: may I pet you
<sham1> zid: having Discord not be shitting the bed is like asking a turtle to not be slow
<Clockface> my favorite thing it did was convince valorant that TPM diden't exist on my freinds computer
<bslsk05> ​'Fastest Turtle you've ever seen' by Nruteron Mountain Sports (00:01:04)
<zid> it's back!
<zid> nice spike on the 'api latency' graph on their service status page though
<gog> Ermine: yes
* Ermine pets gog
<Ermine> gog: my stuff works
<gog> nice
<gog> efi efi efi
<gog> efi haters get rekt
<sham1> Give me bios or give me death
<gog> best we can do is CSM
<sham1> Good enough
<Clockface> what are those open source firmware's for
<Clockface> do people actually install them?
<alethkit> Ye
<alethkit> Yup
<alethkit> Well, Google on their server hardware
<alethkit> And FSF people on their Thinkpads https://libreboot.org/
<bslsk05> ​libreboot.org: Libreboot – Libreboot project
<Clockface> do they only work on a limited selection of PC's
<Ermine> sham1: no bios on arm
<Clockface> just dont use arm
<sham1> I'm not on ARM either
<sham1> (except phone)
<gog> most of EDK is open source
Jari-- has joined #osdev
<gog> prettymuch every vendor uses tianocore
<sham1> Anyway, I do actually like EFI as a concept. However… it feels very Microsoft with all the GUIDs and such
<Clockface> its too complicated
<gog> yeah the whole API looks like COM
<gog> that's very much on purpose
<Clockface> also using PE executables
<gog> makes old windows C coders comfy
<sham1> Yeah, and I'm not a fan of COM
<Clockface> COFF or ELF would be more neutral
<Ermine> Arm is too cool to be avoided
<gog> PE is COFF
<gog> it's ** enhanced **
<sham1> Using ARM is too RISCy for me
<sham1> I can't afford to take the RISC
<Clockface> what even is RISC anymore
<Clockface> ARM has more instructions then older CISC thingies
<sham1> True, ARM isn't even a proper RISC anymore
<Ermine> They are still cheaper on energy
<Ermine> RISC vs CISC is not my primary interest here
<bslsk05> ​redirect -> medium.com: Just a moment...
<GeDaMo> "RISC vs CISC Microprocessor Philosophy in 2022"
<Ermine> bslsk05 failed to follow redirects...
<sham1> Either that or it failed to get the title due to javascript
<sham1> It's Medium, so that's not even an unfeasible situation
<Ermine> That said, I'm not uefi lover
<Clockface> couldn't you just make a BIOS-type interface for ARM
<Clockface> it couldn't be the same thing but you could just have calls that do the same stuff
<heat_> gog, most of EFI is not open source
<heat_> sham1, EFI was created by an ex-nt-kernel guy. explains the ideas and coding style...
heat_ is now known as heat
<Clockface> NT kernel is cool but i don't think its ideas should extend to firmware
<sham1> Well that explains the GUIDs and the strange WinAPI
<heat> and they do not
<Clockface> UEFI gives off windows vibes tho
<heat> sure
<sham1> Yes. Vulkan also does things in a reminiscent way to that
<sham1> So many weird structs linked together to do a thing
<heat> if you think SCREAMING_TYPES are a bad bad idea that should be confined to kernels and not our dear precious firmware
<Ermine> Clockface: then RISC-V comes and everybody would need to reinvent it for RISC-V? And the same goes for any other arch. Also, BIOS is unspecified
<zid> SCREAMING_TYPES is bad in kernels too.
<sham1> IHappenToPreferThisOverScreaminf
<zid> caps is for enums
<zid> not types
<sham1> Although I do also snake_case
<zid> It's like a sign saying "DANGER: Do not evaluate in weird ways"
<Ermine> heat: fuchsia efi headers use their own style
<Ermine> (and those headers are also in ddevault's hboot)
<Clockface> i dont see the problem with reinventing firmware
<Clockface> for different arch's
<heat> Ermine, yes
<heat> Clockface, oh boy
<Clockface> its not x86, so it probably should be kind of different
<Clockface> firmware gets ditched after a few milliseconds so dont overthink it
<Clockface> well i guess maybe a few seconds
<Clockface> since drive is slow
<heat> lol
<heat> drive is slow is BY FAR not the problem in firmware
<heat> gog, do you have the CEO of gays' email?
<gog> i am the CEO of gay
<heat> i tried mikepence@whitehouse.gov but it keeps bouncing
<heat> wow hi mike
<gog> you're fired
<heat> the apprentice gog version
<heat> anyway there's this guy that's super anti-gay in my gym and I wanted to get something SIIIIIIICK like a rainbow-colored nike swoosh tshirt or some shit
<heat> just to spite him. sadly, it doesn't exist
<gog> i was looking at a shirt today, it's a stack of frogs in rainbow color
<gog> idk if you know the yt channel "internet comment etiquette"
<heat> yes i have
<gog> neongrizzly.com
<gog> i want it
<gog> it's expensive tho
<heat> hahahaha
<gog> lmao yeah
<heat> the problem with all these shirts is that they're hard to explain for LITERALLY EVERYONE ELSE
<gog> yeahhhh
<heat> except the gay frogs. just some damn lgbtqi+ frogs dawg
<gog> i'm a gay frog
<gog> the chemicals
<heat> or maybe its just a normal frog company during pride month
<zid> it's not wednesday though?
<heat> no its friday do your research!!!!!
<zid> That's what I am saying
<zid> it's only gay frog day on wednesday
<heat> oh right
<heat> friday is lesbian frogess day
<Clockface> i saw a lizard screwing another lizard and then the other lizard was trying to run away
mahk has quit [Ping timeout: 240 seconds]
<Ermine> heat: UK parliament is the most gay one. You should contact them I guess
<heat> i need a child
<zid> I thought you weren't allowed near children
<GeDaMo> Maybe it comes in adult sizes :|
<zid> How tall are portugal people?
<zid> maybe we can just cram him in
<heat> not
<zid> Dutch people must all be constantly broke from having to buy giant clown shoes
<Clockface> can you make money from having big feet
<GeDaMo> Treading grapes?
<zid> No, they're unnatural giants
<heat> make an onlyfans
<zid> oh, wires crossed
<zid> heat: I made an onlyfans. By which I mean I made a clone website, it's called onlybans. You're banned from it.
<heat> why
<heat> would payment processors not work with you if I created an onlybans
<zid> I can discuss financial information with banned members.
<zid> can't*
<zid> You can upgrade to pro though!
<zid> If you upgrade to pro, for only $2.99 a month, you can get banned twice as long!
<Ermine> what are benefits of pro bans?
<zid> Increased duration, so your ban won't elapse as regularly
<zid> It's annoying to have to reload the website to get re-banned
<Ermine> Ah, I see
<sham1> Suppose I could finally open my IDE for the day. An hour and a half before leaving
<sham1> Fun working like this
<heat> you're a sham sham
mahk has joined #osdev
<Clockface> do new PC's still have the VGA memory area
<Clockface> where you can write pixels or text mode stuff
Jari-- has quit [Remote host closed the connection]
<Clockface> i will take that as a yes
<gog> if you're booting with BIOS you can generally be guaranteed that
<gog> BIOS or CSM
<Clockface> does it exist in UEFI mode?
<Clockface> UEFI has its own text mode routines, so are those a replacement or there to make it easier
<gog> that's more complicated
<gog> sort of
<gog> you can just call SystemTable->ConOut->OutputString()
<gog> but you only have that while boot services is present
<gog> as soon as you ExitBootServices() you need to provide your own text rendering
<sham1> Which you want to do anyway unless you can trust that the hardware font isn't trash on a VGA card or whatever the later emulation brings
<Clockface> hardware font is usually good enough?
<Clockface> i haven't seen a horrible looking one yet
<zid> Can you efi into text mode
<zid> or does it only support lfb stuffs
<mjg> zid: it does not do that
<mjg> zid: it uses "pessimizer"
<bslsk05> ​onlybans.myos.pt <no title>
gildasio has quit [Ping timeout: 240 seconds]
goliath has joined #osdev
<heat> zid, what the actual fuck
<heat> why did you get a domain for a stupid joke
<zid> I didn't lol
<heat> how didn't you
<zid> your browser is weird
<sham1> I smell a wrong MIME-type
<sham1> I also get that
<zid> It has no content-type at all
<sham1> Well okay then, so it defaults to text/plain
bauen1 has joined #osdev
<zid> firefox sees the html and no mime and defaults to text/html
<sham1> You're relying on non-spec stuff
<sham1> Err, I suppose it actually defaults to application/octet-stream instead of text/plain. That's even worse
<sham1> Although reading some stuff, apparently guessing the content type is allowed, so Firefox is actually in-spec
k0valski18891 has quit [Quit: Peace out !]
<heat> yo what the fuck??
<heat> myos.pt is a real thing???
<zid> yea i just quickly found a random website to hack
<heat> what the fuck did you do and why is this not illegal
<zid> (I fixed the content-type now)
<zid> If you have fibromyalgia this is the perfect subdomain for you heat
<zid> onyx.myos.pt
<heat> i have 0 clue what you just did but this is very very unfunny
<zid> why is it unfunny
<zid> I'm having a whale of a tie
<zid> time
<heat> registering stupid joke subdomains under the "national association against fibromyalgia and chronic fatigue syndrome"'s domain is peak banter
<sham1> "whale of a time"
<sham1> I am wonder how that even happened
<sham1> Did you just do a weird DNS trick
<zid> yes, I can speak whale, I asked them to inject it into teh backbone
thatcher has quit [Remote host closed the connection]
heat has quit [Read error: Connection reset by peer]
heat has joined #osdev
<Ermine> gog: gop survives ExitBootServices I guess?
<sham1> You'd hope so, yeah
<sham1> Well at least the framebuffer does
<zid> https://i.redd.it/3mfl21cjv52b1.jpg I love that people are still aware of this meme
<bslsk05> ​i.redd.it: Reddit - Dive into anything
<sham1> Who the hell is Anish Kapoor
<zid> sham fails at knowing the meme
<sham1> I do, yes
<sham1> My meme game isn't that strong
siw5ohs0 has joined #osdev
Left_Turn has joined #osdev
<zid> he's some dickhead who invented a pigment and put really strong licencing terms and price on it so nobody else could use it
<zid> it was 'pinkest pink' or something
<sham1> I see
<sham1> Oh, I've heard of thwt
<zid> so someone made a 'blackest black' and the strong licence agreemet for it was.. you can't be anish kapoor
<sham1> I see
<sham1> Wow, what a dickhead this Kapoor fellow
siw5ohs0 has left #osdev [Leaving]
thatcher has joined #osdev
thatcher has quit [Remote host closed the connection]
thatcher has joined #osdev
Burgundy has quit [Ping timeout: 240 seconds]
<gog> Ermine: the framebuffer does
<gog> wait the bean sculpture in chicago is anish kapoor
<gog> lmao
<gog> worst piece of public art ever
<gog> i have a very old photo of me somewhere reflected in it looking displeased
heat_ has joined #osdev
heat has quit [Read error: Connection reset by peer]
bauen1 has quit [Ping timeout: 240 seconds]
heat_ is now known as heat
<heat> the framebuffer is supposedly reserved in the memory map
<gog> i actually have never seen that
<heat> however: there have been memory map bugs where "normal memory" overlapped with stolen GPU memory
<gog> in ovmf it wasn't but i think they changed that
<heat> oh so: pci memory is not required at all to be represented in the memory map
<gog> i think the efi memory map is just e820 overlaid with allocations from firmware
<heat> you can have gaps, and those gaps implicitly mean "do not touch wildly" but also "may have something there"
<gog> there is a MMIO type tho idk
<heat> there is, motherboard resources for instance are all represented there
<heat> (the upper BIOS range, APICs, etc)
<gog> iirc in the memory map i pass from the loader i do have to mark the area where the framebuffer mmio is
heat has quit [Read error: Connection reset by peer]
heat has joined #osdev
<heat> gog, ok so per the spec, EfiMemoryMappedIO is used for runtime services stuff
<heat> like your flash is necessarily going to be described there, for variable services
<bslsk05> ​uefi.org: 15.4. UEFI Assumptions and Limitations — ACPI Specification 6.4 documentation
<heat> you do need to be careful in not accidentally reporting MMIO as regular memory (e.g the chaos down in the lower 1 MiB)
<gog> marry her
<sham1> What is that, a picture for antsm
<heat> she was asking me for money
<heat> that's normal right?
<GeDaMo> Isn't he dead? How can he be 'embattled'? :|
<GeDaMo> Zombies :|
siw5ohs0 has joined #osdev
siw5ohs0 has left #osdev [Leaving]
<heat> muammar gaddafi is jfk jr
<gog> i am muammar gaddafi
<heat> marry me embattled president muammar gogdafi
<gog> i do
Burgundy has joined #osdev
vai has joined #osdev
vai is now known as Jari--
ZipCPU has quit [Quit: ZNC 1.7.5+deb4 - https://znc.in]
slidercrank has quit [Ping timeout: 240 seconds]
ZipCPU has joined #osdev
PublicWiFi has joined #osdev
[itchyjunk] has joined #osdev
Turn_Left has joined #osdev
Left_Turn has quit [Ping timeout: 240 seconds]
gildasio has joined #osdev
[_] has joined #osdev
[itchyjunk] has quit [Read error: Connection reset by peer]
<heat> is there an inline assembly hint for the compiler to re-align the stack?
Brain__ has quit [Read error: Connection reset by peer]
<sham1> Probably not
goliath has quit [Quit: SIGSEGV]
slidercrank has joined #osdev
<kazinsal> hmm. I probably shouldn't buy an IBM 5150 sight unseen from ebay with no returns and no display to plug it into
<geist> correct!
<geist> i have seen some for sale around seattle/vancouver on craigslist, but usually pretty pricey
<geist> thought about picking one up but really i have no desire for early PC hardware
<mjg> loller
<mjg> you reminded me of a polish practice on polish equivalent of ebay
<kazinsal> it looks like it's got a fully populated SixPakPlus in it though...
<mjg> you got a piece of hw which is broken? you claim you have no means to test
<mjg> ;d
<geist> mjg: yeah ebay the equivaent i've seen is 'no power cable'
<geist> i assume that's jist code for 'doesn't work'
<geist> also other problem is frankly with anything old and doubleplus with a CRT in it, i just dont trust the shipper to package it, it'll just get broken in transit
<geist> but local pickup you at least dont have that problem
<geist> basically feels like you're doing the world a disservice by getting something fragile shipped by amateurs
<kazinsal> 270 cad + 100 cad shipping from quebec. looks like it has a CGA and two 5.25s but no monitor
<geist> might not be bad, because shipping monitors...
<kazinsal> yeah
<kazinsal> I was hoping to find something like this locally but no dice in vancouver
<kazinsal> maybe I'll drive down to seattle during my vacation this summer and just hand someone a wad of cash for a whole unit
<bslsk05> ​portland.craigslist.org: Original IBM PC Personal Computer restored full setup - computers -...
<geist> but a) it's pricey, and b) it's in portland
<geist> 3 hour drive from here, but like a days drive for you
<geist> it's been for sale for a few months, probably because it's too pricey
<kazinsal> oof, yeah, that's a bit high on the price scale
<kazinsal> and about six hours yeah
<kazinsal> plus whatever daily shenanigans happen on I-5
<geist> they also have a XT clone and a 286 compaq. looks nice though
<geist> i have a long ass search with craigslist that catches some stuff and some in the vancouver area too, since it's hypothetically worth driving there
<geist> "historical | historic | vintage | microvax | vaxstation | commodore | atari | tandy | amiga | alpha | dec | terminal" is my search term. seems to work okay
<geist> though it picks up lots of newer 'vintage' computer listins where someone lists their old laptop from 4 years ago as vintage
<kazinsal> yeah, that's why I tend to include seattle in my search list. I'll do a weekend trip down there and back for neat gear
<geist> i had an amiga pop up that i kinda wanted a month or so ago but was about to go on a trip
tomaw has quit [Quit: Quitting]
<geist> kinda want this: https://vancouver.craigslist.org/rch/sys/d/richmond-west-hard-drives-jaz-left/7608304386.html but dont want to drive up there for it
<bslsk05> ​vancouver.craigslist.org: Hard Drives - Jaz - 1 left - computers - by owner
<geist> but it doesn't mention having any actual disks, which may be hard to get
innegatives has joined #osdev
tomaw_ has joined #osdev
<kazinsal> ooh, yeah
tomaw_ is now known as tomaw
<kazinsal> plus it would require navigating richmond by car, and that's something you need to bless your vehicle with a pint of holy water to do successfully
<geist> of all the things i purged years ago i kinda wish i still had the scsi zip drive + disks
<geist> was pretty good for interfacing with old hardware with scsi
[_] is now known as [itchyjunk]
dude12312414 has joined #osdev
<geist> though really with all the scsi 2 sd adaptors nowadays that problem is solved
<geist> does kinda remind me, i wonder what the actual protocol was for parallel zip drives. wouldn't be surprised if it was just scsi over parallel, since they sold scsi versions of the same drive side by side
<kazinsal> I'd imagine so
<kazinsal> probably just a cheap little board waiting for a whole scsi packet's worth of data on the parallel line before blasting it to the actual scsi controller on the drive
<kazinsal> atapi but for ieee-whatever
<gog> hi
* kazinsal pets gog
* gog prr
<geist> yah scsi is so flexible like that. the protocol dont care how it gets the data
<innegatives> what are disadvantages of writing your kernel in C++ except for the things you have to take into account listed in osdev wiki for C++ page?
* geist pets gog
<geist> innegatives: that's baout it
<geist> it works okay, you just have to be more generally aware of what the language is doing uner the hood. i wouldn't recommend it unless you're at least moderately experienced
<geist> in C++
<kazinsal> the ghost of linus torvalds will haunt you and call you finnish profanities in the dead of night
<geist> if you're trying to build a kernel for very small computers, or low end hardware it's a bit more of an ask. C++ *tends* to generate more code to do the same thing
<geist> maybe not slower, but tends to be more code due to lots of inlining of things, generally more so than C
<geist> i say tends because there are ways to avoid it, etc etc. but on the average i've generally seen more codegen in C++
<innegatives> Is there any reason why we haven't seen a serious pure-Rust kernel yet?
<geist> probably just too soon. i've seen many attempts. mostly in embedded space
<innegatives> Nothing over 100k lines
<innegatives> geist: is it just too hard to get right with current state of the lang?
<geist> kinda the biggest thing i've seen in that space is the starnix project we're working on on fuchsia, but it's not a true kernel per se
<kazinsal> probably the os hobbyist equivalent of organizational inertia
<kazinsal> we're all just so used to hacking away at C and/or C++
<geist> it's a user space server emulating linux
<heat> rust is garbage rust is garbage rust is garbage rust is garbage
<geist> yah i've been working on a C++ kernel for the last 7 years and it's generally okay
<kazinsal> rust looks kinda neat but I haven't really felt the need to learn it
<heat> cargo
<innegatives> by the way, my emulator has a screenshot now: https://github.com/jafarlihi/core86
<geist> it's fairly clear at least in the circles i'm in that rust is going to be more or less The Thing for a while
<bslsk05> ​jafarlihi/core86 - [WIP] 8086 IBM PC emulator (0 forks/9 stargazers/MIT)
<geist> so i'm slowly picking it up
<kazinsal> I'm still trying to figure out the previous decade's hot newness
<geist> what is generalyl happening is companies that are into security/safety/etc, like a lot of FAANG are basically flipping their thought process internally to: justify why you can't write <new project> in rust
<geist> ie, it's starting to become the default
<geist> old projects have inertia, but thers's also a move to rewrite in rust
<geist> whethe ror not it's actually earned, or a good idea, etc i dunno
<geist> but the Cargo Cult is fully engaged now
<geist> but so far seems to be performing well, etc. so i guess it's sort of sticking
gog has quit [Quit: Konversation terminated!]
<innegatives> what is the reason for openbsd's lack of reported vulnbs even tho they use C?
<kazinsal> yeah I get why it's the new standard going forward
<heat> because no one uses openbsd
<geist> innegatives: because you can write good code in any language
<geist> dont get too fixated on the notion that the language is the solution
* Ermine is Fuchsia UI
<geist> the language just helps do this or that. you can write good or shitty code in any language
<innegatives> geist: so how come openbsd coders write better code than linux coders?
* geist shrugs
<kazinsal> smaller project, smaller goals
<heat> <heat> because no one uses openbsd
<geist> bingo
<kazinsal> linux needs to run on everything from a literal toaster to a supercomputer
<kazinsal> and it needs to scale well
<geist> you can focus on different aspects of the same thing
<kazinsal> openbsd doesn't because the project isn't meant for that
<heat> it's easy and rewarding to find vulnerabilities in linux, because it supports a lot of things and it's used EVERYWHERE
<heat> if you find a vuln in openbsd you... get some routers?
Left_Turn has joined #osdev
<kazinsal> most of the security errata for openbsd have been in openssh/openbgpd/openospfd/libressl
<geist> innegatives: also whether or not openbsd is better or not re: vulns is probably debatable, but that's how they market it and they still seem to care. so good for them
<kazinsal> which are components that are widely used outside of the openbsd OS itself
<geist> think of it as a marketing thing. they worry about security more, and thus they try to be more aggressive abut fixing them, not writing them in the first plac,e and then they market that they're doing a good job
<geist> good for them
<kazinsal> yeah
<innegatives> can you guys suggest something i can work on to git gud besides an OS?
<geist> the whole 'rust is a more secure language' thing does not mean other languages are intrinsically not secure
<kazinsal> really, I consider openbsd a neat unix that serves primarily as a reference distribution for the portable components that the project produces
<geist> it's just *generally* harder to write certain class of common security vulns in rust because it's much strictr about various things
<geist> kazinsal: yeah
<kazinsal> eg. openssh came from openbsd and openbsd is the reference distribution that includes it but you find openssh on practically every linux machine (and windows machines for the past half a decade or more)
Turn_Left has quit [Ping timeout: 240 seconds]
<geist> way back about 20 years ago i also found openbsd's firewall config and features really nice compared to the other BSDs
<geist> ran a low end openbsd box for like 5-8 years as my router in the late 90s, early 2000s
<kazinsal> yeah, pf is a pretty straightforward but flexible firewall
<kazinsal> I still use it but that's because I'm an incurable dork
<geist> yeah somewhere in the mid 2000s i switched to m0n0wall (which is freebsd based) and never switched to anything else
<kazinsal> though I'm thinking about buying a cheap juniper firewall through work since we get a massive discount on not-for-resale products
<geist> m0n0wall got renamed into pfsense. been happy with it
Left_Turn has quit [Ping timeout: 264 seconds]
Left_Turn has joined #osdev
goliath has joined #osdev
<Ermine> I wonder why windows bitlocker wants recovery key after my efi hello world was run
<geist> interesting
<geist> maybe it sensed a non signed 'bootloader' ran and that forces some sort of re-auth?
<geist> because it assumes you futzed with the disk?
<geist> (assuming you actually didn't trash the disk)
<geist> do you have secure boot on?
<Ermine> No, it's off
<Ermine> I only print hello world, should be no disk interaction
<geist> dunno then
<Ermine> Anyway, rebooted and it calmed down
<geist> but yeah aybe there's some sort of handshake your hello is 'supposed' to do
<geist> so possibly windows sees it as a incomplete boot or something
<kazinsal> yeah it's probably assuming that whatever other EFI application is running that's not signed by a key in the TPM is a potential security risk
<geist> so it' being extra careful
<heat> that could fuck with the TPM
<geist> that being said i switch between linux and windows on the same machine all the time, and it doesn't have this issue
<geist> though i use secure boot now, but before i didn't
<Ermine> My app returns then windows boot proceeded
<geist> OTOH, efi grub maybe pets things 'properly'
<geist> ah maybe that's it. windows efi app is maybe seeing that it's not the firt thing that's run so it's being paranoid?
<Ermine> maybe it didn't like return code
<geist> or that
<geist> if you exit boot services and then stop in your hello world, then reboot the machine does windows do the same thing?
<geist> ie, is it because windows is booting in the same boot instance?
<Ermine> I don't exit boot services
<geist> sure. but i'm saying if you *did*
<geist> ie, instead of exiting the app, try stopping such that you have to physically reboot the machine
<geist> then see if windows detects that
<Ermine> Ok, will take a look at that
<geist> that makes more sense, otherwise the windows app would have to 'remember' across boots that something else ran
<geist> but if it's in the same instance of efi, may be easy for it to query that something ran before it
<geist> i'm just making this all up, just trying to guess what's going on, FWIW
innegatives has quit [Ping timeout: 240 seconds]
innegatives has joined #osdev
gog has joined #osdev
<Ermine> brainstorming is good too
<geist> yeah. hmm, what were those elephant lookin alien race in Mass Effect
<gog> hi
<geist> they always prefix their sentences with the mood, intent, etc
<geist> i do that sometimes at work. like
<geist> suggestion: blahblahba
<Ermine> hi gog
<geist> or brainstorm: <some crazy idea>
<gog> onomotopeia: meow
<geist> Elcor, that's the race
innegatives has quit [Ping timeout: 240 seconds]
innegatives has joined #osdev
<bslsk05> ​vancouver.craigslist.org: TI99/4A Vintage Computer - computers - by owner
<geist> heh, no power cable
<geist> thogh this one seems kinda legit, like the guy actually doesn't know if it works because they didn't really want to use it as a computer
<gog> the ebay post said it was functional
<gog> the case seems to be in good shape
<gog> probably fine
<kazinsal> heh
<kazinsal> wonder how much of a pain it'd be to find/build a new power supply for it
<kazinsal> iirc it's an external brick on the 99/4A
<gog> didn't adrian black have to do exacyl that
<gog> or was it a different computer
<kazinsal> oh god this might be one of those crazy 80s computers that needs a bunch of AC voltages
<kazinsal> yep looks like the external power brick spits out a handful of AC voltages and then the rectifier is internal to the machine
<geist> not sure, i thought ti/99s had an internal psu
<geist> ah. yeah okay
<geist> lots of those did the AC thing, C64 did too
<geist> since it wasn't a switched supply, i guess that meant they could put the large transformer outside
<geist> you should read about the internal arcitecture of the ti99, it's a real disaster. actually 16 bit cpu, but can ony access memory via some other chip, etc
<geist> it's a real disaster. basically running an interpreter
<geist> the cpu is a microprocessor version of an existing minicomputer they had
<geist> the main disaster about it is TI tried to control it too tightly and killed the entire software ecosystem for it. so it basically had like 20 carts or whatnot
<kazinsal> yeah, the tms9900
<kazinsal> architecturally it's fascinating
<geist> one of those cautionary tales. back in the day the most open 8 bit computers generally won
<geist> totally
<geist> iirc it's the one that has like 3 internal registers andone of them is 'where is the base in memory of the 16 pseudo regs'
<geist> so context switch is just move the base pointer
<kazinsal> yeah, their logic was something like since the machine has basically a "zero page" of zero wait state SRAM you might as well just use that for all your register files
<geist> right. an era when ram was faster than the cpu
<geist> would be entertaining to get one of the microprocessors from it and breadboard up something that works better than the ti99
<kazinsal> totally
<kazinsal> it seems like a pretty competent arch especially for a late 70s VLSI implementation of a minicomputer
<geist> iirc the ti99's problem is it has somethingl ike 1K or whatnot of actual address space that the cpu can use natively and then Real Memory you have to literally access via pokes and peeks through the video chip, or something
<geist> presumably because they didnt/couldn't wire up a cheap 16 bit memory bus across the wole machine
<geist> would be too expensive etc
<geist> 256 bytes!
<bslsk05> ​www.unige.ch <no title>
<kazinsal> jeez
<kazinsal> I can see why it didn't do so hot in the market
<geist> ah okay, it wasn't as bad as i thought: it's *video* ram that you can't access directly, but main ram is there, it's just 2x8 multiplexed so it's slow
<geist> basically extra wait states
<geist> so presumably you kept your register file in the 256 byte area so it'd be fast
<Ermine> Do I understand correctly that intended way of getting memory map in UEFI is GetMemoryMap(&MapSize, NULL, NULL, NULL, NULL); AllocatePool(EfiLoaderData, MapSize, &Map); GetMemoryMap(&MapSize, &Map, /* whatever */);
<Ermine> ?
<geist> something like that? there's some case where the map can change out from unerneath you so you have to retry, i think
<geist> like the map object goes out of scope
<geist> but i dont remember the details. i think heat has worked in the efi bits more
puck has quit [Excess Flood]
<Ermine> UEFI requires map to be obtained right before ExitBootServices
puck has joined #osdev
<Ermine> So they even ask for MapKey in ExitBootServices
goliath_ has joined #osdev
<geist> i think one of the things that extbootservices guarantees is that the memory map stops changing
<gog> yes
goliath has quit [Ping timeout: 240 seconds]
goliath_ has quit [Remote host closed the connection]
jeaye has joined #osdev
<gog> so whatever way you allocate for the memory map also cannot change it. i think what i do is i make one call to get the current size of the memory map and then allocate that plus sizeof memory descriptor
<gog> or it's what i did at some point
<gog> i think now though i just allocate that from a bump allocator i use to store boot data
<gog> i can't be bothered to remember or read my own code
<geist> priot to exiting boot services isn't there more of a malloc style thing? ie AllocateMemory(bunch of flags)?
<geist> or is the alloatepool thing Ermine linked it?
<gog> that can change the memory map
Turn_Left has joined #osdev
<geist> oh for sure, but do you have to do the get map/allocate/loop dance?
<gog> or rather, it can cause a region to be split and add a descriptor
<geist> totes
goliath has joined #osdev
<Ermine> There's AllocatePool and AllocatePages for malloc thingie
<geist> i get that the map object is instantly obsolete the instant you allocate or change the map, but do you eed the map to allocate
<gog> no, if you pass nulls to two of the params it'll tell you the size
<gog> iirc
<gog> nulls and a 0 to buffer size
<gog> and it'll return EFI_BUFFER_TOO_SMALL
<geist> it's definitely a weird interface, very win32ish (no surprise)
<gog> yeh
innegatives has quit [Quit: WeeChat 3.8]
<gog> i don't actually hate it
bgs has joined #osdev
<gog> but it's definitely not how i'd desgin an api
Left_Turn has quit [Ping timeout: 256 seconds]
<geist> nah, and you can also always wrap these with more familiar apis
<gog> too many VERY_LONG_AND_LOUD_TYPE_NAMES
<geist> i guess it's not win32ish in that a lot of the apis dont just take a pointer to a structure with args init
<gog> does the spec pre-date stdint?
<geist> almost certainly. late 90s
<geist> or at least original EFI was ITANIUM!
<gog> stdbool too probably then
<gog> ITANIUMMMMM
<geist> dunno how much UEFI has diverged, but i think it was more or less just EFI vs 2 or whatnot
<sham1> IA64 my beloved
goliath has quit [Read error: Connection timed out]
goliath has joined #osdev
goliath has quit [Quit: SIGSEGV]
GeDaMo has quit [Quit: That's it, you people have stood in my way long enough! I'm going to clown college!]
Jari-- has quit [Remote host closed the connection]
<mrvn> does exitbootservice modify the map to include the ram that ending boot services frees?
<mrvn> gog: M$ didn't implement C99 (stdint) for the longest time
<mrvn> a bunch of unix APIs also take a size argument for a buffer and return the needed size and then you call them with size 0 to find the right size. Bunch of those though allocate if the buffer is NULL itself.
<puck> mrvn: boot service memory is separate from runtime service memory in the memory map, iirc
<mrvn> puck: that doesn't answer my question even if you were sure
<puck> anyhow
<puck> > A UEFI OS loader must ensure that it has the system’s current memory map at the time it calls ExitBootServices().
<puck> > [..] In addition, the UEFI OS loader can treat all memory in the map marked as EfiBootServicesCode and EfiBootServicesData as available free memory
<puck> mrvn: also, how could it modify the memory map? you have to pass in a buffer yourself
xenos1984 has quit [Ping timeout: 248 seconds]
xenos1984 has joined #osdev
<mrvn> puck: you pass the map you have to exitbootservices
<mrvn> 20:31 < Ermine> So they even ask for MapKey in ExitBootServices
xenos1984 has quit [Ping timeout: 248 seconds]
<puck> mrvn: map *key*
<puck> not pointer
<puck> you get both the memory map and map key back from GetMemoryMap https://uefi.org/specs/UEFI/2.9_A/07_Services_Boot_Services.html#id15
<bslsk05> ​uefi.org: 7. Services — Boot Services — UEFI Specification 2.9A documentation
xenos1984 has joined #osdev
goliath has joined #osdev
Brnocrist has quit [Ping timeout: 268 seconds]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
Brnocrist has joined #osdev
<gog> yes the key is like a crc32 of the memory map i think
<gog> or maybe a value taht gets incremented every time the map changes?
<gog> idk i've never looked at it
<mrvn> maybe it's opaque.
<zid> crc32(sha1(crc32(region1)+region2)+region3) ofc
Brnocrist has quit [Read error: Connection reset by peer]
<gog> mrvn: the memory map isn't altered during ExitBootServices(). there's a table of memory types you're allowed to reclaim after though
<bslsk05> ​uefi.org: 7. Services — Boot Services — UEFI Specification 2.10 documentation
<mcrod> hi
<zid> we've already got one thanks
<gog> hi
<gog> zid
<zid> glowgun
<gog> do you have a moment to talk about our lord and savior jesus christ?
<zid> No, you're confused, I follow the church of RMS
<zid> Our lord and savior, richard "can I lick your wife's toes?" stallman
<gog> close enough, beardo weirdos are a dime a dozen
<mcrod> church of root mean square
Brnocrist has joined #osdev
<mcrod> gog: i had a long day. discuss.
<gog> what's troubling you friend
<mcrod> i had to do boring things today like plot data and present it over a teams meeting
<gog> oooooooof
<zid> I am of the church of eastern calculus
<gog> i am the church of baphomet
Brnocrist has quit [Read error: Connection reset by peer]
bgs has quit [Remote host closed the connection]
<mcrod> i wonder if the US will default
innegatives has joined #osdev
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
<mrvn> There are only 2 allowed religions: Worshiping the invisible pink unicorn and the spaghetie monster.
<kof123> yes, this makes sense, that is basically perl6 versus perl5
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
<innegatives> Some guy on this channel had GH repo with scripts to build GCC cross compilers, anyone knows who it was?
<mrvn> the wiki has step by step instructions
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
<gog> mcrod: the us won't default, the debt ceiling is a legislative gridlock tool
<gog> it's design to bring chaos
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
wootehfoot has quit [Ping timeout: 240 seconds]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
<mrvn> They will just stop paying wages.
Brnocrist has joined #osdev
slidercrank has quit [Ping timeout: 265 seconds]
Brnocrist has quit [Read error: Connection reset by peer]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
<gog> been a minute since the US had a good ol government shutdown
<gog> i remember the one in like 2012 some scammer called me claiming to be from the IRS and i'm like breh the IRS is not operating
<gog> https://www.youtube.com/watch?v=4jM13eQWAwA in more important news
<bslsk05> ​'low poly cat set to low quality funkytown' by murderousroomba (00:02:00)
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
<mrvn> "So Darwin was right about God but wrong about Evolution?"
danilogondolfo has quit [Quit: Leaving]
Burgundy has quit [Ping timeout: 240 seconds]
Brnocrist has joined #osdev
<heat> <gog> does the spec pre-date stdint?
Brnocrist has quit [Read error: Connection reset by peer]
<heat> they avoided standard C like the plague
<heat> lots of long time firmware engineers know jack shit about standard C
<gog> i feel like it was a huge mistake
<heat> does this pre-date stdint? yes, slightly
<heat> does it matter? no, they took a crap on everything else too
<heat> e.g the tianocore DEBUG (()) macros take format-ish strings that REALLY do not represent reality
<heat> you'll notice %x is UINT32, %lx is UINT64. how do you print UINTN? you cast to UINT64 and use %lx obviously!
<heat> also note: %lx is UINT64 even on platforms where it isn't
<heat> it's brilliant!
antranigv has quit [Ping timeout: 240 seconds]
<gog> cute
<gog> efi is really great
<gog> i hate standards
xenos1984 has quit [Ping timeout: 240 seconds]
Brnocrist has joined #osdev
<heat> <geist> dunno how much UEFI has diverged, but i think it was more or less just EFI vs 2 or whatnot <-- UEFI is EFI but with a different spec version yeah
<heat> most firmware people still call it EFI, internally it's still "EFI"
<heat> UEFI is just a plot to get more people onboard (see, it's UNIFIED!)
<zid> uefi is the i586 of x86s
<zid> and by x86s I mean x86, not x86s which would be x86ss
<zid> simples
<heat> i love x86s's
Brnocrist has quit [Read error: Connection reset by peer]
<heat> this is seriously unpronounceable wtf
<heat> thank fuck no one is using this until 2080
Brnocrist has joined #osdev
<heat> geist, i actually had an older intel uefi big hat tell me something like there's a distinct advantage in developing a new solution. like for fairness or "inclusiveness". it ends up working better than telling people "use my thing, it's better than yours"
<heat> in which case the U in UEFI makes a lot of sense
<heat> EFI, but this time, it's US. where its basically the same thing but slightly changed and has a different name
<gog> youeefi
<heat> and you'll implicitly trust it a lot more than if its entirely my thing
<heat> because WE designed it
<heat> even if effectively nothing changed
<gog> it's unified and extensible
Brnocrist has quit [Read error: Connection reset by peer]
<mrvn> heat: and that's why we have this horrible PRI*
xenos1984 has joined #osdev
Brnocrist has joined #osdev
<gog> zid: that's a proper earth
<zid> High quality ethically sourced earth
antranigv has joined #osdev
<zid> In an artisinal presentation pouch
<zid> and custom mount scheme
<gog> very quality
Brnocrist has quit [Read error: Connection reset by peer]
Turn_Left has quit [Read error: Connection reset by peer]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
innegatives has quit [Quit: WeeChat 3.8]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
Brnocrist has joined #osdev
Brnocrist has quit [Read error: Connection reset by peer]
<zid> good news, apparently windows xp now has a keygen