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
wildo has quit [Remote host closed the connection]
<heat_> "The only things which change i_disksize are ext4_get_block (growth) and ext4_truncate (shrinkth)."
<heat_> shrinkth
netbsduser has quit [Ping timeout: 246 seconds]
<zid> should be shrinketh
<mjg> thou shalt shrinketh
<bslsk05> ​'If YouTube Polyglots Were Honest' by Language Simp (00:03:40)
ski has quit [Ping timeout: 255 seconds]
Arthuria has quit [Ping timeout: 272 seconds]
thinkpol has quit [Remote host closed the connection]
thinkpol has joined #osdev
ski has joined #osdev
gog has quit [Quit: byee]
<kof673> > i think the i860 > i'm sure i saw such in the mach sources was used there too although i think those were somewhat rare/pricey: > NeXTdimension board provides 32-bit color, and includes an Intel i860 not sure how much access you had to it or if anything emulates it nowadays etc.
<kof673> in any case, for both those reasons, i think next headers had little bits and pieces
navi has quit [Quit: WeeChat 4.1.2]
gildasio has quit [Remote host closed the connection]
gildasio has joined #osdev
goliath has quit [Quit: SIGSEGV]
Stary_ is now known as Stary
Arthuria has joined #osdev
Arthuria has quit [Ping timeout: 256 seconds]
Arthuria has joined #osdev
fkrauthan has quit [Quit: ZNC - https://znc.in]
<adder> I'm trying to load idtr, but qemu keeps rebooting.
fkrauthan has joined #osdev
<adder> I'm calling an asm function like this: load_idt(sizeof(idt) - 1, &idt), and I'll show now my routine.
fkrauthan has quit [Client Quit]
<bslsk05> ​bpa.st: View paste VP7A
Arthuria has quit [Killed (NickServ (GHOST command used by Guest684531))]
Arthuria has joined #osdev
<adder> struct idt_entry idt[TOTAL_INTERRUPTS] = {0}; This is how I'm initializing it. struct idt_entry is 8 bytes total.
<adder> TOTAL_INTERRUPTS is 256.
fkrauthan has joined #osdev
<adder> Shit. Seems like now I don't even survive loading gdt.
<adder> Seems like I'm loading it but if I don't halt I die, and if I sti I also die.
Arthuria has quit [Killed (NickServ (GHOST command used by Guest684531))]
Arthuria has joined #osdev
netbsduser has joined #osdev
m3a has joined #osdev
netbsduser has quit [Ping timeout: 264 seconds]
Matt|home has joined #osdev
<bslsk05> ​i.imgur.com <no title>
lentement has joined #osdev
lentement has quit [Ping timeout: 240 seconds]
terrorjack has quit [Quit: The Lounge - https://thelounge.chat]
ski has quit [Ping timeout: 264 seconds]
terrorjack has joined #osdev
<Mutabah> adder: Nice
<adder> :)
<klys> ye ye neat.
asarandi has quit [Quit: WeeChat 4.1.1]
netbsduser has joined #osdev
asarandi has joined #osdev
ski has joined #osdev
netbsduser has quit [Ping timeout: 264 seconds]
xFCFFDFFFFEFFFAF has quit [Quit: 0xC0190060 STATUS_EXPIRED_HANDLE]
winwin_ has joined #osdev
sbalmos has quit [Ping timeout: 260 seconds]
sbalmos has joined #osdev
[Kalisto] has quit [Ping timeout: 255 seconds]
[Kalisto] has joined #osdev
netbsduser has joined #osdev
netbsduser has quit [Ping timeout: 264 seconds]
elastic_dog has quit [Ping timeout: 264 seconds]
elastic_dog has joined #osdev
heat has joined #osdev
heat_ has quit [Read error: Connection reset by peer]
Arthuria has quit [Ping timeout: 268 seconds]
ski has quit [Ping timeout: 252 seconds]
netbsduser has joined #osdev
<geist> yay
<geist> getting htat first interrupt handled and returning is a pretty cool feeling
netbsduser has quit [Ping timeout: 256 seconds]
polezaivsani has joined #osdev
<kazinsal> been watching this youtube channel where this lineman in new brunswick just... records the shit he does on a day to day
<kazinsal> real fascinating stuff
<kazinsal> though whenever he's up a pole I get that "oh dear" heights feeling just watching him do stuff haha
lentement has joined #osdev
netbsduser has joined #osdev
<clever> kazinsal: bob?
<kazinsal> yep
<clever> yep, ive been following him for about a year as well
<clever> how did you notice he was in NB?
<clever> he usually tries to hide it
<clever> but even in the very first video, i could tell he was local, just from the bloody trees and mountains in the distance, lol
<kazinsal> saw a vid where he was on the coast and you could see across to nova scotia
<clever> first vid i stumbled into
<clever> ahh
<kazinsal> I'm from the other side of the country but having driven up that way on a road trip one summer it's a pretty distinct sight haha
<clever> a couple times, i have pin-pointed the exact substation or transformer he was working on
<clever> but i'm on the north end of NB, and he is generally on the south end
<kazinsal> turned my old man onto his channel as well. dad was with BCtel for 34 years starting as a lineman (and trained linemen through his entire time even when he became a fibre guy) so he's got an appreciation for the art
ThinkT510 has quit [Quit: WeeChat 4.2.1]
ThinkT510 has joined #osdev
netbsduser has quit [Ping timeout: 264 seconds]
lentement has quit [Remote host closed the connection]
lentement has joined #osdev
lentement has quit [Read error: Connection reset by peer]
lentement has joined #osdev
ski has joined #osdev
<geist> huh pretty impressive. just noticed that ubuntu running under WSL2 on windows actually has nested virtualization enabled
<geist> oh yeah i think i know what you're talking about re: the linesman in canada
<geist> my dad was watching that a bit too
<geist> or at least *a* youtube channel about a linesman in canada somewhere
<geist> there can't be more than like 1 of those right?
<clever> i would assume there is only 1 bob doing it right now, lol
zetef has joined #osdev
<clever> the scene isnt that packed!
<kazinsal> a bob whose name is actually not bob
<clever> yeah
<kazinsal> so y'know, narrows it down
<kazinsal> add in the canadian factor and that functionally narrows us down from a country of 40 million to a dartboard of 40 thousand
<geist> right
<geist> and then the number of them doing youtube channels, etc
<clever> https://www.youtube.com/watch?v=KFnhQSrnQk0 or i could just ruin the entire search and link his latest vid :P
<bslsk05> ​'Energizing new construction!' by Bobsdecline - Lineman blogger (00:24:49)
lentement has quit [Read error: Connection reset by peer]
<geist> yep, bobsdecline
lentement has joined #osdev
<kazinsal> so you end up with "this east coast canadian youtube lineman" and the six canadians with family histories of electrical or telco trades in the chat simultaneously go "oh you mean bobsdecline"
<geist> also i enjoy the HVAC guy, i think he's in los angeles
<geist> there's also a guy that keeps old oil derricks going that is pretty interesting
<clever> yep, HVACR
<geist> very much redneck engineering
<clever> i first found him with a disgusting ice machine cleaning video
<kazinsal> his recentish video with the utility arborists is great. mostly just listening to a bunch of arborists shouting at each other in the most stereotypical canadian accents and slang known to god and man
<geist> heh yeah there was one a while back where bob was fixing some sort of connection to a house and the owner was out in a thick canadian accent talking at him
zetef has quit [Ping timeout: 255 seconds]
zetef has joined #osdev
<kazinsal> yep, that's the maritimes for ya right there bud
<geist> oh oh that reminds me, lemme find it
<geist> i rememeber seeing this fisherman video in a museum in nova scotia, i think lunenberg
<geist> had the thickest maritime accent i've ever heard (though i havne't heard a lot)
<geist> then i found it on youtube at some point
lentement has quit [Read error: Connection reset by peer]
<clever> something ive been saying for years, and never even realized was an acent, i say acrosst but spell it across
lentement has joined #osdev
* kof673 points at wednesday
heat has quit [Remote host closed the connection]
heat has joined #osdev
<kazinsal> yeah, I didn't realize I had any sort of accent until I read a thing about the hybridization of canadian english and american PNW english accents that vancouver natives have
<kazinsal> and was like, ah, shit, yeah
<clever> my dad has also mentioned the differences between quebec french, nb french, and france french
<geist> man i cannot find this thing :(
<geist> https://youtu.be/banAMiFK3ak is pretty solid though
<bslsk05> ​'Newfoundland accent' by Loading (00:02:11)
<clever> geist: oh, that reminds me, one of my dads co-workers was on a flight, and had some kind of medical emergency
<clever> he woke up in the hospital with 3 pints of newfie blood, and an urge to fill out an unemployment form
<kazinsal> that's a good solid newfie accent
<kazinsal> the kind where you can hear the irish
lentemen_ has joined #osdev
<geist> ahahah
<clever> kazinsal: ive got some scottish in my family tree, grandmother on my fathers side was a mkcay
gbowne1 has quit [Quit: Leaving]
<clever> but i can barely make out that newfoundland accent
<kazinsal> yeah, vague nebulous mix of great britain and ireland here
<kazinsal> couple rumoured bastards etc
lentement has quit [Ping timeout: 264 seconds]
<geist> oh also impressive, i just build qemu from source inside WSL2 and with GTK support it even opens a native window
<kazinsal> the kind what got shipped off to ireland and then off to canada afterwards
<geist> and does nested KVM
<clever> nice
<clever> ive also heard that qemu has support for the native virtualization tech on windows and apple
<clever> so the native windows/mac versions should also hw accel
<geist> it definitely does on apple, i even use it
<geist> on x86 and ARM
<geist> in fact i have some outstanding bug where LK wont boot on it and i think i know why
<geist> it's because the start.S code that sets up the page tables uses 64K pages temporarily, and M1 cpus dont support those
<clever> ahh
<clever> of note, the pi5 supports 16kb pages, and that is prefered, more bang for each TLB slot
lentemen_ has quit [Ping timeout: 240 seconds]
<clever> but some userland libraries use 4k alignment, and then mmap fails
<kazinsal> yeah, M1 does the 16KiB as well
<geist> yep. pretty much all ARM cores post about a55/a75 support the full suite of page granules
<clever> i think pi5 is only 4k and 16k
<geist> M1 is a weird outlier: 4k and 16k only
<geist> clever: nah it does 64k
<clever> ah, not sure why they arent going with 64kb then
<geist> who, apple? because they dont use it
<clever> rpi 5
<geist> they do 64k
<geist> cortex-a76 does 4k, 16k, and 64k
<geist> i dont know of an ARM, Ltd core that doesn't do all three *after* a75 and a55
<bslsk05> ​forums.raspberrypi.com: Just a moment...
<clever> > Why to run 16k page size for RPi5?
<geist> bug what you *might* be thinking about as does linux support it
<geist> that's for different reasons
<geist> the hardware supports it
<geist> i'm not sure precisely what linux's support is nowadays for non 4k page granules. it might support all 3 now
<geist> but then you have to make sure everything is compiled correctly, etc
<clever> what i know at least, is that kernel8.img, is a 4k aarch64 build of linux, that works on both pi4 and pi5 families
<geist> yep
<clever> while kernel_2712.img is a 16k aarch64 build, that only works on the pi5
<geist> yep. because pi5 supports 16k
<geist> whereas previous cpus did not
<clever> kernel=kernel8.img is the fix, for when you have aarch64 libraries with non 16kb alignment in its .text
<geist> yep
<geist> this is all cromulent
netbsduser has joined #osdev
<clever> i need to get a uart cable for my pi5, and try porting LK to the arm side
<geist> yah i bought one of the debug things
<geist> it's kinda nice. haven't used it on the pi5, but i'm using it on a rpi2040
<geist> er pico
<clever> the fun thing, is that the debug port has both uart and swd
<geist> yep
<clever> i believe that debug port is also gpio, on the SoC
<geist> new picos even switched to the new connector to match the debug module
<clever> and you could have the pi5 debug a pico, by just connecting the debug ports together
<clever> i have made openocd work on the pi5, via the main gpio and libgpiod, the speed is horrible
<clever> massive cpu usage
<clever> pcie latency, and overheads of the whole gpiod framework
<clever> hmmm, now that i think about it, if you do a read over pcie, and the cpu stalls, what would `top` report that stall as? plain used cpu? targeting the context (kernel/user) that did the read?
<geist> yes
<geist> think of it as a really long instruction
<clever> makes sense
<clever> but if you make the debug ports kiss! lol, then you can use the SoC gpio
<geist> though of course the OOO cpu will try to keep going, etc
<clever> which will have a far lower latency
heat has quit [Remote host closed the connection]
<clever> ive tried to have somebody else test that, but they couldnt get it to work, and didnt have the right hardware to debug it
<clever> oh, and doesnt LK have some semihosting console stuff?
<clever> maybe i'm just imaginging that
<geist> possibly
<geist> in some fork of it yes
<clever> that would be useful, due to swd and uart sharing the pins
heat has joined #osdev
<clever> and where was that other trick LK had up its sleeve....
<clever> ah there it is, _debugger_info
<clever> only on arm-m though
netbsduser has quit [Ping timeout: 260 seconds]
gog has joined #osdev
kfv has joined #osdev
polezaivsani has quit [Remote host closed the connection]
[Kalisto] has quit [Ping timeout: 272 seconds]
kfv has quit [Quit: Textual IRC Client: www.textualapp.com]
netbsduser has joined #osdev
elderK has quit [Quit: WeeChat 4.1.1]
winwin_ has quit [Ping timeout: 260 seconds]
<mjg> so i accidentaly found out that akira toriyama passed away
<mjg> rip
<mjg> if you don't know who that is you might a boomer or a genz
<heat> clever, fyi userland that does 4K alignment isn't ARM64 abi compliant
<heat> they explicitly require 64KiB alignment in the abi (for ELF headers) for this exact reason
GeDaMo has joined #osdev
rustyy has quit [Quit: leaving]
<clever> heat: i'll keep that in mind for next time i see the issue
<mjg> aight, enough reddit
<clever> i would also assume, binary patching of the .so should be feasible, at least if its a section problem
<mjg> wtf am i even reading
<bslsk05> ​old.reddit.com: Just unsubbed from MakeupAddiction because I am sick of posts from crossdressers every day : JustUnsubbed
<clever> just pad things out
<clever> but if its bad code passing things to mmap, all bets are off
<heat> clever, no, you'd need the relocations for that
<heat> which you dont have
<clever> heat: but if you prepend nulls to the LOAD?
<kazinsal> I would recommend, at first shot, not reading reddit
<kazinsal> if that's unavoidable, then I recommend not reading reddit communities designed to faux outrage
<heat> clever, prepend, append, probably won't work
<clever> lets say something wants to load to an addr like 5kb, and thats not 4kb aligned, just prepend 3kb of nulls, and adjust the relocations so they have the right offset into the new blob
<kazinsal> failing that, unplug your router
<heat> but that doesn't work, you dont have all the relocations, you can't possibly know if someone was referring to something before or after the nulls
netbsduser has quit [Ping timeout: 268 seconds]
rustyy has joined #osdev
<clever> heat: i meant more, that if something wants to be loaded at addr 0x12345678, and thats not aligned right, prepend some nulls, so it does land at that addr
<clever> the worst that will happen, is that you have some extra pages mapped before the desired mapping
<clever> by reducing the addr in the LOAD statement, and then padding it back up with nulls
<clever> so in the virtual space, nothing has moved
<clever> then relocations shouldnt even come into play?
<heat> i guess if you only do it in the file it /might/ work, but then what happens to the LOAD addresses?
<clever> round it down to the nearest alignment boundary
<clever> and add that to the size
<heat> you can't touch the LOAD addresses
<clever> why not?
<heat> because then you require relocations
<clever> are the relocations addressing things in the virtual or file space?
<heat> virtual
<clever> so if you where to say reduce the LOAD addr by 4k, but then prepend 4k of nulls to the actual section in the elf file
<clever> then the bytes in the file still wind up at the same virtual addr as before
<clever> so the relocations still point to the same opcodes
<heat> oh i think aligning the first section to 64K might just work
<heat> as long as you don't want or need permissions
<heat> or weirder mappings (but it's usually not required, ELF linkers usually have contiguous segments)
<clever> yeah, i would need to find one of these offending elf files first, to see what its layout looks like
<heat> apple has a fun hack in the kernel where if a 4K aligned mmap comes up they just create a new vm object that re-pages everything into 64 KiB pages
<heat> which i assume they needed for rosetta
<clever> that reminds me, i noticed some weirdness with wine many years ago
<clever> the main .text of an exe wasnt mapped, but copied to private ram
<clever> after digging, i discovered that the .text in the exe, wasnt 4kb aligned in the raw file
<clever> so mmap just cant do the job
<clever> wine detects this failure, and then just allocates some ram, and copies the whole section over
<heat> yeah PE files can be pretty crazy
<clever> i had also discovered the relocation cache in windows at one point
<clever> from my understanding, windows will pre-patch the dll with relocations, and then save the patched version to disk
<clever> so it can just map that pre-patched version next time
<clever> but i think linux PIC mode avoids that, by concentrating all of the relocations on just a single lookup table, and indirecting everything with pc-relative stuff?
<heat> yes
<heat> .text relocations defeat .text sharing
<clever> yeah
<bslsk05> ​github.com: darwin-xnu/bsd/kern/mach_loader.c at main · apple/darwin-xnu · GitHub
<clever> and at that point, its purely just looking up each symbol, by adding the load offset of other libs, and filling the addresses in on the LUT
<heat> apparently not in mmap but just the loader
<heat> i assume they further hack around this in rosetta itself
<kazinsal> PE is nuts but it's because it was extended from COFF and COFF was one of those pre-ELF attempts at a unified format for unlinked and linked object formats
<kazinsal> it's not bad, it's just... odd
<clever> and isnt mach-o another unified format?
<kazinsal> especially with the bits of MZ/NE bolted onto it
<heat> it's also all in CamelCase and we don't like that do we
<kazinsal> yeah, mach-o is similar but independently developed
<sham1> COFF is nuts
<sham1> ELF on a SHELF
<clever> lol
<kazinsal> PE is weird to get your head wrapped around but all in all it's not horrendous
<kazinsal> having dedicated section stuff for things like code signing makes it neat
<heat> i hated it
<heat> but the code signing is nice
<heat> linux people: code signing? what's that?
<sham1> Packages get signed
<sham1> You don't really need the code signing unless you'd be doing proprietary stuff, since the point of signing is to be able to verify that the program is what it claims to be and from the vendor it claims to be from
<heat> packages being signed means nothing when you don't check it after installation, ever
<heat> you can't ever enforce the rule
<sham1> The signatures get checked when the package is being installed and updates. At least on Fedora
<heat> doesn't matter
<sham1> The package manager does it automatically and barfs on you if the signature doesn't matcj
<clever> the only commercial reason i can see for code-signing is DRM
<clever> gotta make sure the user doesnt control anything in the path of the video data, those pixels are special!
<sham1> I can see why you'd be confused, you use Arch, which for the longest time didn't sign the packages
<kazinsal> dd if=/bad/shit/here of=/your/executable skip=arbitrarynumber count=payloadbytes
<kazinsal> oof ouch my package signing
<heat> what kazinsal said
<sham1> I could do that on Windows as well and the package signing wouldn't save me
<sham1> Err, executable signing
<heat> sure it would
<sham1> No it wouldn't. If I zero out the PE file, it no longer has anything in it
<heat> "bad executable, get fucked"
<kazinsal> authenticode says "zomg a tampering, no execute 4 u"
<sham1> Also, doing a dd onto an executable is a deliberate choice
<kazinsal> whereas I jam a payload into an ELF and Linux goes "yum yum punch it"
<heat> it's a deliberate choice or you're running malicious software that just injected a payload in any one of your system libraries or executables
<heat> but ofc linux can't ever reject running malware because code signing is not a thing
<sham1> How would malware do it
<heat> i'll make sure to install my next malware through pacman
<sham1> It can't write in /usr/bin
<heat> root
<sham1> How did it get root
<clever> sham1: i didnt update my mail server, and it was running as root
<clever> true story :P
<kazinsal> I'm sure every one of those packages your distro installs from some weirdo's github actions is flawless
<heat> there has been a grand total of 0 root exploits ever
<kazinsal> load bearing port of a gtk2 sub-library
<heat> not to mention people just giving root to everything that moves
<clever> they replased `ls` with a custom binary, that would lie about the existance of the malware
<clever> they where sloppy, and it didnt support `ls -lh`, instantly breaking my monitoring scripts
<sham1> It's not my fault people do `curl | sudo sh`
<clever> so i detected them within minutes
<sham1> Also also, you could just propose new code signing segments and sections for ELF
<sham1> Nothing's stopping you from doing that
<kazinsal> several groups have done so
<kazinsal> none have caught onj
<kazinsal> nobody wants to standardize
<clever> ive also seen a blog post about the failings of several methods
<clever> like only signing the .text, but then the relocation data isnt signed, and is turing complete
<clever> or something like that
<heat> STANDARDIZED 🤮🤮🤮🤮
<kazinsal> openbsd almost got there but they didn't do an ELF extension for signify to do codesigning, just package and kernel update signing
<kazinsal> but, honestly, if they had? no one would listen
<sham1> Well yeah, when you have people like heat and mjg badmouthing them, of course no one would listen
<heat> good
<heat> ELF signing will never catch on because MUH LOCKED DOWN SYSTEM and MUH GPLV3+
<kazinsal> people have been asking for a canonical codesigning system for ELF for almost three decades
<kazinsal> but nope, we can't have that
<sham1> Why were they rejected
<heat> because they'd break emacs :v
<clever> heat: nix and nixos basically solve the problem, by just serializing the entire package into a blob, and signing that blob
<clever> and at runtime, every file in the package is read-only
<kazinsal> Free Software (tm) is incompatible with authoritative signing of binary packages
<sham1> But emacs works in Windows
<clever> there are tools to verify the files havent been modified, and you could use namespaces to enforce that it remains read-only
<heat> clever, that doesn't work
<clever> why doesnt it work?
<sham1> Also, you can have the authoritative signing authority of a binary be the distribution
<heat> if i fuck your filesystem, or get root, chmod +w and write to it
<sham1> They already sign the packages, they can sign the binaries
<clever> heat: thats why i mentioned namespacing, so normal root doesnt have permission to do that
<heat> the best thing we have atm is fs-verity and dm-verity, but you need those to make sure no one fucked with the contents
<sham1> So anyway, Windows simping aside, how is today for people
<kazinsal> neither the FSF nor Greenpeace are dead yet so it's not good
<zid> busy simping sh
<zid> I mean, shh
<zid> not simpling shells
<sham1> I need to actually get going on my daily cycle ride, I just feel lazy today
<kazinsal> good ol' sh. the lowest common denominator that works in the "I need to get this system usable by other, more competent systems" sense
<sham1> I like sh as a simple bootstrapping lowest common denominator, like this guy: https://www.etalabs.net/sh_tricks.html
<bslsk05> ​www.etalabs.net: Rich’s sh (POSIX shell) tricks
<sham1> You know that the site is good since it's unstyled
<kazinsal> it is convenient that you can render the same page on a modern 2024 system using $insert_chromium_fork_here and an early 90s machine using some backport of Mozilla 1.4 and they look the same if you just don't put any CSS in
<sham1> And use HTML that existed for both
<kazinsal> 12pt Times New Roman looks the same regardless of decade
<sham1> I might be a weird person, I still use Mozilla. Well, Firefox
<zid> chrome is garbo
<zid> people use it from momentum
<sham1> Yes
<sham1> Chrome sucks
<kazinsal> I've been using Vivaldi for a long while
<kazinsal> chromium engine, opera functionality, and much better per-thread paging than chrome
<heat> i switched to chrome from firefox because firefox sucked
<heat> i don't regret it
<heat> big up chrome
<sham1> God damn zoomers
<heat> firefox was buggy and slow
<sham1> Contributing to the browser monopoly
<kazinsal> apparently there's a mail client in vivaldi but outlook exists so meh
<heat> chrome is fast and not-buggy
<sham1> > outlook
<sham1> > chrome
<sham1> > not-buggy
<GeDaMo> I mainly use Firefox, I use Chromium for some sites which won't work without disabling all my extensions
<kazinsal> outlook's fine, sorry about your inability to adapt to the professional world
<sham1> I remember just like two weeks ago, I had to fix a chrome bug in our program because they broke lazy image loading between versions
<heat> kazinsal, outlook is awful to use and all your emails look weird because mUH HTML EMAILS
<kazinsal> user skill issue
<sham1> This but unironically. HTML emails are a plague, and also bad for accessibility
<kazinsal> switching to plaintext emails is one button or one shortcut
<kazinsal> any linux dork who can't figure that out is a shameful linux dork
<heat> yes but i need to communicate with people that don't have plaintext emails
<kazinsal> that's what html emails are for
<heat> and those use HTML emails, have the NDA disclaimers and the external email disclaimers
<kazinsal> are you proposing an RFC for markdown emails
<heat> and those people are usually the ones doing fucking TOP POSTING
<kazinsal> default to html. use specific rules to respond as plaintext. manually override to plaintext where those don't work
<kazinsal> as long as you don't press the RTF email button you're fine
<heat> either that or they say "hey, replies inline"
<heat> > someone said something
<heat> [heat] you're a fucking idiot
<heat> where you could skip the top posting and the [heat] stuff
<heat> it's *almost* good and i appreciate people trying, but it's not the real thing
<kazinsal> anyone who gives a shit about that manually rewrites their postings
<kazinsal> if you're using outlook and you are a mailing list user you will put in the extra 30 seconds to make sure your posts look good regardless of client
<heat> anyway, gmail is better
<heat> no, that's not true, because corporate people don't care
<sham1> I like inline replies. Better for context. But I can deal with bottom posting in a pinch
<heat> or don't know
<kazinsal> even though 80 columns per line is stupid as fuck in 2024
<kazinsal> hurf blurf gotta make all our posts conform to a VT100
<heat> my biggest gripe with gmail is the silent wrapping of text
<heat> so now i just write really long lines and hope it looks okay when i send it out
<sham1> kazinsal: what is format=flowed :S
<kazinsal> average screen dimensions: 240 characters per line at 8x16
<clever> kazinsal: one issue i often have, is that things line `man` do line-wrapping without involvement of the tty, and then when i copy/paste to something 5 characters more narrow, every 2nd line has 1 word on it, lol
<clever> if you let the tty wrap things, then the artificial linebreaks wont wind up in the clipboard, and it will continue to wrap nicely in the next place
<sham1> I don't like how man hard-flows your text. But that's why I like Emacs. That handles the flowing of the text just fine
<clever> but maybe i shouldnt be copying from the text mode man client?
<clever> the html versions ive often found on google, let the browser do the wrapping, and then the problem doesnt exist
<clever> and i'm sure a local client doing the same must exist?
<sham1> But yeah, 80-column email is no longer an issue, because you can have the email text get reflown as it ought to be by the client.
<clever> but, will the email client properly understand what it means, when every line starts with a > ?
<heat> i'm a programmer, i don't want my text reflown
<clever> would respecting an 80 column layout cause it to waste space?
<sham1> The email client can still type it to respect the 80-column display internally for legacy clients, while letting proper email clients read the thing nicely, because you have format=flowed on the MIME header
<sham1> Well, the Content-Type mail header, as defined by MIME
<clever> oh, and on the subject of email and gmail
<mjg> sham1: dude what
<clever> every time i turn around, gmail is blocking me from sending email, claiming spam
<mjg> sham1: i'm literally building openbsd up
<clever> i'm on a static ip, and am fairly certain i have never sent spam
<mjg> sham1: that is to say my criticism understates their breakage
<clever> just shut up and accept my email already, lol
<kof673> this seems like tab-width debate in disguise
<mjg> maybe previus ip owner did?
<mjg> besides afair they normally go for ip blocks
<clever> mjg: i have had this ip for years
<mjg> 12:15 < mjg> besides afair they normally go for ip blocks
<clever> every time i fix things to make them happy, they break it again
<mjg> so you got liek /24 slashed
<mjg> possibly because someone else did on another ip
<clever> let me see what they are claiming today....
<sham1> Also, for what I hope is not actually a hot take: columnar text is good, actually
<mjg> columnar text?
<sham1> Maybe not restricted to 80 columns, maybe you can go up to like 100, 120-ish. But that's still good, you don't want your text to go from one edge of your screen to the other
<mjg> haters are going to say you are wasting sapce
<sham1> There's a reason why newspapers and research papers are printed in columns. If anything, some might claim that 80 columns is too wide
<mjg> .besides.rust.encourages.chaining.funcs.so.fuck.you
<sham1> It's down to how human vision works
<mjg> mate everyone doing actual work probably agrees
<mjg> short lines is where it;s at
<clever> mjg: ah, having trouble finding errors in the logs, maybe they havent f'd it up in a while
<clever> or i just neglected this too long, and forgot where to look, lol
<clever> 2024-03-06 00:26:00 H=(WIN-4TTI4DH7SGH) [194.48.251.24] F=<spameri@tiscali.it> rejected RCPT <spameri@tiscali.it>: relay not permitted
<mjg> ask chatgpt
<clever> at least the spammers are nice enough to self-report, lol
moberg has joined #osdev
<sham1> Anyway, time for the cycling™
Matt|home has quit [Remote host closed the connection]
<mjg> i think i found my people on reddit
<mjg> r/petsfree
<mjg> erm, r/petfree
<mjg> they are shitting on dogs and cats more than i'm shitting on solaris
<mjg> it is a little circlejerky though
<zid> No no he wanted to spame
<mjg> as in apart from legit criticism they seem to look for reasons to be offended by mere existence of dogs
<zid> That's completely different
<Ermine> mjg: where do you find those weird subreddits
<mjg> dude
<Ermine> mon
<bslsk05> ​subredditstats.com: Related Subreddits By User Overlap
<mjg> type in something you know and go down the reabbit hole
<kof673> mjg, re: akira https://www.youtube.com/watch?v=UA13icbjAvw you will note he acquires excalibur IIRC and splits a rock IIRC when you are trying to position him :D
<bslsk05> ​'Chrono Trigger - Frog's theme on guitar' by GuitarWanker90 (00:02:53)
<Ermine> > minix
<heat> openbsd is not in the database
<Ermine> > subreddit not found
<Ermine> bruh
<bslsk05> ​subredditstats.com: Similar Subreddits To r/bsd By User Overlap
<bslsk05> ​subredditstats.com: Similar Subreddits To r/freebsd By User Overlap
<heat> weebs in 7th place
<bslsk05> ​i.imgur.com <no title>
<mjg> heat: check out the 3rd place
<bslsk05> ​subredditstats.com: Similar Subreddits To r/badmathematics By User Overlap
<mjg> cursed fucking website
<heat> lmfao
<bslsk05> ​subredditstats.com: Similar Subreddits To r/soccer By User Overlap
<heat> in r/soccer you're more likely to be portuguese than any other nationality
<heat> suck it fuckheads
<mjg> you must be from portugal to think it's a good thing
<mjg> soccer aka football is BASIC BITCH sport
<heat> fuck you
<mjg> probably it's what makes it so popular in poland as well
bitoff has joined #osdev
<heat> mjg, here's a cursed issue: "SRWLOCK can grant exclusive ownership when we requested shared ownership"
<heat> lmfao
<mjg> is that a bug description?
<mjg> smells a little like implementation artifact which was left on purpose
<mjg> and only documented
<mjg> so what happens when you unlock that sucker?
<heat> i don't know, this is weird
<heat> doesn't look documented
<heat> it's a bug on microsoft's c++ standard library
netbsduser has joined #osdev
<GeDaMo> Solution: update documentation to describe program's actual behaviour :P
<heat> the underlying win32 rwlock is shitting the bed
Nixkernal has joined #osdev
<heat> you can actively deadlock by doing two read_locks in a row, this is insane
<heat> why would anyone ever do this even
<mjg> from one thread?
<heat> yep
<mjg> this is a typical problem with rw locks
goliath has joined #osdev
<mjg> people keep finding out the hard way
<heat> if SRWLOCK gives you exclusive first, i don't imagine you get anything other than a deadlock
<heat> what is?
<mjg> typically rw locks have some sort of "writer starvation prevention"
<mjg> which stops more read lock requests from going through
<mjg> if you have a codepath which read locks the s ame sucker twice
<mjg> and someone else sets the "writers are waiting bit, fuck off" in the middle
<mjg> you deadlock
<mjg> everyone's first rw lock
<mjg> rust folk also ran into this problem
<mjg> :d
<mjg> freebsd bypasses the problem by counting if you have anything held for reading, if so this protection is bypassed
<mjg> however, while there probably is a legitimate case where you want to take the same lock twice, you are most likely fucking up by finding yourself in this spot to begin with
<heat> musl doesn't do any of that shit
<heat> i'm not sure if glibc does either
<mjg> i meant kernel
<mjg> for posix locks who the fuck knows
<mjg> there is probably something retarded in there because someone lost a bet or was high while writing it
<heat> if you need write throughput you're better off using RCU
<heat> vs playing crap games with other threads
<mjg> it's baout limitng tail end latency
<mjg> fucker
<heat> yes, just don't use it
<mjg> besides, solaris does not have rcu and scales
<mjg> !
<heat> can't get latency if you never wait
<mjg> or you have legit reasons to read lock
<heat> i'm yet to see a rwlock that can't be RCU-ified
<mjg> what if it did not happen yet
<mjg> and you got tons of these
<mjg> (did i mention solaris?)
<heat> make it happen if thats a problem
<mjg> besides rust recommends rw locks
<mjg> i'm sticking to the FEARLESS
<mjg> did you know rust allows you to fearlessly deadlock without any diagnostics
<heat> good
<nikolar> FEARLESS
<heat> mjg, btw the OG repro of that issue is something like: get N threads, all of them lock it in shared mode, wait for every thread to rendezvoux, unlock
<heat> which sometimes never happens because 1 thread ends up getting it exclusively and no one else gets the lock
<heat> which makes even less sense
<mjg> lol
<mjg> now that is funny
<mjg> but also, indeed if you read lock so much, maybe you are f-in up?
<mjg> some rust aficionados there
<heat> apparently its the lock convoy busting
<bslsk05> ​github.com: `<shared_mutex>`: `SRWLOCK` can grant exclusive ownership when we requested shared ownership · Issue #4448 · microsoft/STL · GitHub
<mjg> but again how do they read unlock in the fast path then
<mjg> is that a cmpxchg loop?
<heat> *shrug*
<heat> hey siri, can you please fetch me the NT4 leak and check how SRWLOCK works
<mjg> least slow way for one-worded lock is to lock xadd
<mjg> but they can't do it if the reader gets a surprise write lock
<heat> (SRWLOCK is vista)
ski has quit [Ping timeout: 256 seconds]
lentement has joined #osdev
vdamewood has joined #osdev
vinleod has quit [Ping timeout: 246 seconds]
heat_ has joined #osdev
heat has quit [Read error: Connection reset by peer]
<sham1> God damn ice fuckin' shit
<sham1> Also special mention: Gravel
<sham1> I couldn't ever really speed up because if I had to turn, I might have slipped and fell due to all the fucking gravel on the street
<Mutabah> Isn't the idea of gravel to increase traction?
<sham1> Yes! When there's ice! But in those sections of the street the ice had already melted
<sham1> So you had spots with ice without any gravel, and where the ice had all these bumps from partially melting and freezing again, and then parts without ice with a fuckton of gravel
<sham1> My commute route is fine, but my Saturday route? Not so much
<sham1> I can only shudder how it will be on my Sunday route, since that's even more "out of the way"
Nixkernal has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
Nixkernal has joined #osdev
goliath has quit [Quit: SIGSEGV]
lentement has quit [Remote host closed the connection]
lentement has joined #osdev
lentement has quit [Ping timeout: 255 seconds]
<zid> heat_
<zid> pouuguese island, 7 letters
<GeDaMo> Is it also a cake? :|
* kof673 grudgingly gives gedamo alchemy points
<GeDaMo> I used Wikipedia :P
<zid> yea it was cake
<zid> they typoed and wrote island but meant to write ake
navi has joined #osdev
* kof673 .oO( hot-cross bun, and is a figure of the land that was caked or coagulated ) i wouldn't make that up zzzzzzzzzzzz dissolve...and cake....
heat__ has joined #osdev
heat_ has quit [Read error: Connection reset by peer]
winwin_ has joined #osdev
Left_Turn has joined #osdev
rustyy has quit [Ping timeout: 252 seconds]
goliath has joined #osdev
vdamewood has quit [Ping timeout: 260 seconds]
vdamewood has joined #osdev
rustyy has joined #osdev
lentement has joined #osdev
heat__ has quit [Read error: Connection reset by peer]
heat_ has joined #osdev
lentement has quit [Ping timeout: 256 seconds]
heat__ has joined #osdev
heat_ has quit [Read error: Connection reset by peer]
winwin_ has quit [Read error: Connection reset by peer]
lentement has joined #osdev
lentement has quit [Ping timeout: 268 seconds]
FreeFull has quit []
gorgonical has quit [Ping timeout: 260 seconds]
Arthuria has joined #osdev
goliath has quit [Quit: SIGSEGV]
zxrom has quit [Quit: Leaving]
polezaivsani has joined #osdev
goliath has joined #osdev
polezaivsani has quit [Remote host closed the connection]
heat__ is now known as heat
heat has quit [Read error: Connection reset by peer]
heat has joined #osdev
lentement has joined #osdev
lentement has quit [Ping timeout: 260 seconds]
ski has joined #osdev
dude12312414 has joined #osdev
dude12312414 has quit [Remote host closed the connection]
<bslsk05> ​lwn.net: Adding systemd to postmarketOS [LWN.net]
<heat> when more musl distros switch to systemd the musl people will have a meltdown
<mjg> :d
<mjg> i thought alpine is also moving?
<mjg> face it, not using systemd on linux is like using bsd
<heat> i don't think so, not yet at least
<heat> but yeah the anti-systemd crowd should fuck off to bsd
<heat> particularly one very resistant to change (unless its the one they like), whose name i wont mention
dude12312414 has joined #osdev
Turn_Left has joined #osdev
Turn_Left has quit [Read error: Connection reset by peer]
Turn_Left has joined #osdev
xenos1984 has quit [Read error: Connection reset by peer]
<geist> wow, much vitriol
<geist> did rc.d touch you in a bad place heat?
<kof673> lol gesit well, it is a lack of DEVELOPERS or people who want to maintain a distro. and, reality is not perfection, but, the old joke was bsd people like unix, xyz hate ms :D
Left_Turn has quit [Ping timeout: 272 seconds]
<kof673> meaning...you can always just play anti-xyz against eachother etc.
<heat> geist, my desktops have always been systemd :p
<heat> i'm a linux user post-systemd-switch for the most part
<geist> yes i forget that you're like 14
<heat> 12
<heat> pre-pubescent
<geist> my general complaint is it's lots of the time much harder to figure out how to do what was before simple
<geist> ends up being search the net for stackoverflow
<heat> thankfully there's an arch wiki :P
<geist> since it ends up being some monolithic thing you have to interact with on its terms. there's a lovely simplicify to edit a file
<heat> which i do use, btw
<geist> an example: nfs automount is completely ubtuse on systemd, you have to just search for the magic syntax, put it in fstab and hope it works
<kof673> by "play" i just mean...will they stick around, or abandon it as soon as bsd does something they don't like :D
<geist> tweaking fstab is another one, you can tweak it, but systemd wont pick it up unles you do <other magic invocation>
<heat> i tend to find systemd very easy to use, sometimes they take some .ini-like config files but it's ok
<heat> some stuff is definitely strange but there's usually good reason for it, shell scripts just dont cut it
<geist> except they did and still do for non systemd
ski has quit [Remote host closed the connection]
<geist> shell scripts *can* cut it, systemd just chose a different path
<heat> they can, but it's just slower
<heat> and clunkier
ski has joined #osdev
<heat> when i found out for my netbsd installation i had to much around rc.d scripts to bring up wifi networking... lol
<geist> dunno what's so lol about that, you edit the files
<heat> it's a horrible experience if i need to screw around with literal source code to enable and disable stuff
<kof673> ^ should just be config variables IIRC also, <awards points for "vitriol">
<geist> 100% disagree
<geist> but doesn't matter, systemd is around nowadays so <shrug>
<heat> where in systemd i just do systemctl enable networkmanager and it Just Works for every wifi interface i have up
<heat> and Just Working tends to be nice for UX
<geist> sure.
<geist> most of my linux boxes except a few are headless, so they have different concerns
<geist> where command line is the UX
<heat> it might be nice to think of a UNIX system as something super simple, where it's just you and the shell and C and whatever
<geist> where possible, yes.
<heat> but it doesn't cut it for modern (desktop, server) systems
<kof673> i don't follow these things, but have seen claims systemd is more dynamic and responsive, versus general "one-time" startup of services. and the video talked about launchd on macos something or other
<geist> disagree
<heat> or at least for a modern experience
<kof673> i think it was a bsd guy saying not to hate on systemd IIRC lol
<kof673> that it should be examined for ideas at least...
<geist> but yeah i dont really disagree about systemd working well in a modern thing
<geist> i just disagree with the sort of backwards statement that everything prior to it is terrible
<geist> it's more like it solves things in a more modern way, and that may or may not be 'better' on various axis
<geist> but it's sort of irrelevant
<geist> it feels a lot like similar arguments re: rust or whatnot. 'now that rust is here everything that isn't it was always terrible'
<heat> i'm not saying its terrible, i'm saying its worse
<geist> well, you were sort of saying it was horrible at least
<geist> and loling about it
<heat> it's horrible *for me*, where i've never known anything other than systemd for "real system usage"
xenos1984 has joined #osdev
<heat> i probably have a very different perspective from you
<geist> whe you gonna port systemd to onyx? :)
<heat> idk never really seriously thought about it
<geist> just terrible shell scripts for onyx it is!
<heat> no, i have some pseudo-crappy init system that takes pseudo-crappy inis
<heat> very systemd style :)
<geist> heh
<geist> i remember back at palm for webos we wrote something like that too
<geist> similar reasons: the default run of shell scripts on a like 400mhz ARM actually took like 10 seconds
elastic_dog has quit [Ping timeout: 246 seconds]
<geist> there was something like 1000 forks with the shell scripts. what was the starting distro.... openembedded i think?
<heat> my system takes like... 8 pids when starting up :)
<heat> not counting with kernel threads or threads in general
<geist> it is astonishing to see how fast small systems boot on modern hardware huh?
<Ermine> mjg: re systemd on alpine: it was explosion, not a meltdown
Left_Turn has joined #osdev
<heat> geist, definitely and its still PESSIMAL
<geist> PESSIMAL!
<Ermine> <heat> but yeah the anti-systemd crowd should fuck off to bsd <--- nah
<heat> Ermine, but you'll love linuxulator :(
<Ermine> defo i won't
<nikolapdp> how about systemd croud fucks off to bsd
<heat> anyone using systemd will not have fun using openbsd
<netbsduser> nikolapdp: i can facilitate that having ported systemd to all 5 BSDs
<nikolapdp> lol
<heat> see, i can't even name 5 BSDs
<Ermine> much to their disdain
<netbsduser> the biggest sin of systemd is that it is linux engineering
Turn_Left has quit [Ping timeout: 255 seconds]
<heat> you don't like the linux engineering ethos? :(
<nikolapdp> i definitely wouldn't call it linux engeneering
<netbsduser> it works if you have lots of people firing away at it
<heat> it is most definitely linux engineering
<netbsduser> but the heart of systemd hasn't
<Ermine> no, it doesn't have girl kissing
<netbsduser> no one cares about service management, at least they don't care about the sort of service managing that systemd does
<netbsduser> they do care about big orchestrators and such but those are obviously excessive for this purpose
<Ermine> Btw i'm that anti systemd guy that daily drives systemd distros
<nikolapdp> yeah same
<heat> aren't you using alpine
<Ermine> no
<nikolapdp> i am on artix, but work computer is ubuntu
<heat> oh wait yeah you used fedora wasn't it?
<Ermine> yes
<heat> why do you not like systemd?
lentement has joined #osdev
<netbsduser> i am quite anti systemd so i felt the best way to give credence to my opinions was to port it to the OS i daily drive and set out a plan on how i'd like to butcher and refactor it
elastic_dog has joined #osdev
<heat> if you say "BLOATED" while explaining yourself i have to take a shot
<Ermine> because systemd-oomd killed my browser for no reason in the worst possible moment
<nikolapdp> BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED BLOATED
<heat> Ermine, is that it?
<Ermine> i'm pretty sure
<heat> cuz the kernel OOM killer is also capable of making really bad decisions
<nikolapdp> randomly killing processes you don't want killed isn't good enough reason for you?
<heat> usually worse than systemd-oomd i've heard
<nikolapdp> i am pretty sure kernel isn't nearly as agressie
<heat> yes, the kernel only kills when the system is completely hosed
<heat> as in you can't use it
<netbsduser> i don't know anything about SystemD-OOMD but i assume it must be configurable, probably not as configurable as it ought to be, but surely it is
<heat> that's why you use oomd
<Ermine> that time it was ubuntu which just adopted systemd-oomd at that moment
<heat> out of all the times my system had severe memory pressure my system came out of it alive like... single digit percentages
<Ermine> And according to phoronix news I wasn't the one in ubuntu with such issues
<nikolapdp> heat for me it's like 90% of time
<nikolapdp> you just need to be patient
<heat> if i have to wait hours i might as well just reboot
<Ermine> No shit, idea of service management is good, but impl is meh
<nikolapdp> it's not hours it's like 10 minutes
<nikolapdp> at most
<heat> 10 minutes usually doesn't cut it for me, and i have fast storage
<netbsduser> Ermine: this is one of the big problems i have with the systemd "debate"
<Ermine> don't join systemd debates
lentement has quit [Ping timeout: 255 seconds]
<netbsduser> it is millions of people who don't know the first thing about anything other than phoronix poasting
<heat> yes, join #musl and get stuck in the systemd debates accidentally
<heat> UGH WHY IS THE SYSTEMD PROTOCOL SO BLOATED
<heat> FUCK
<Ermine> heat: or in initrd+udev debates
<netbsduser> and a common thing is identification of systemd with complicated service management functionality, as if the two are one and even elementaries like the concept v.s. implementation distinction are lost
<Ermine> the one was in -offtopic recently iirc
<heat> c++ bad, gnu bad, systemd bad, comments bad, subscribe to my onlyfans
<heat> oh modern web bad
<nikolapdp> c++ bad indeed heat
<nikolapdp> that too
<netbsduser> they seem to have a user called midipix in #musl, which is interesting because midipix was supposed to be some chap's new windows subsystem for unix applications
<heat> yes its the author
<Ermine> So far the closest alternative to systemd in terms of service management is s6-rc, but...
<heat> the UNIX philosophy crowd is anti anything that makes your UNIX-like system not work like a 1980s system v derivative
<heat> C++?!? In my UNIX?! we only had C back in the day, and we were better for it
<nikolapdp> linux rejected c++ heat
<nikolapdp> why don't you copy that
<netbsduser> you missed illumos SMF which is very comparable but more robustly engineered (both in terms of broad architecture but also in terms of not repeatedly using alloca() with unbounded, user-controllable sizes)
<heat> i wish i did but C++ is also actually actively useful
<netbsduser> but porting SMF to gnu/linux is harder than porting systemd to bsd
<heat> and its not a huge problem because i'm mainly the only one writing code for onyx
<nikolapdp> have you tried netbsduser
<heat> so i can be exactly as anal as i want it to
<Ermine> heat: my friend does cursed things with the freshest c++(20?) features to fight with qt deficiencies
<netbsduser> yes, after a week i had the components building and identified what i needed to rewrite to enable a port
<nikolapdp> when are we seeing smf powered linux then lol
<netbsduser> i would have to shim or rewrite all its use of IPC, which rests on solaris doors, and i would have to shim or rewrite the process contracts stuff
<Ermine> like perfect forwarding
<heat> SOLARIS DOORS!
<netbsduser> and when i have a burst of energy aimed in that direction i will look into both
<nikolapdp> ILLUMOS DOORS
<heat> mjg, the doors implementation did it go anywhere
<Ermine> Also, my take, unix philosophy is poorly defined term in the first place
<netbsduser> i think it might mean all things to all men
<heat> unix philosophy is both a horrible stuck up philosophy from the 70s and something that was progressively added to by other people
<heat> everything is a file is *not* unix philosophy
<netbsduser> to me it means communicativity, modularity, a big central abstraction (the file descriptor), and all that follows from it
<mjg> heat: down the drain
<heat> doors can't fit into drains
<netbsduser> this is not completely met by real unix (processes not being referred to by FDs is the most stinking oversight) but that's all the worse for unix that it's not embodying the unix philosophy well enough
<heat> the minimal crowd thinks "inetd | tlsd | httpd" is genius engineering that will totally work amazingly well in 2024
<heat> netbsduser, pidfd!
<netbsduser> heat: they fucked it up
<heat> why?
<heat> it seems to do the job, systemd is a big fan
<Ermine> good fit for one cases and bad fit for others
<netbsduser> the pidfds don't behave like proper open files which have the rights associated with who opened them originally (regardless of who now has an FD)
<netbsduser> this is an unbelievable kick in the teeth to anyone who believes in the potential of pidfds for privilege separation
<Ermine> I do use "inetd | tlsd | httpd" and it works amazingly well for me
<netbsduser> they should be capabilities
<heat> Ermine, does it even have light traffic?
<netbsduser> however they *are* robust handles which makes them infinitely superior to PIDs
<Ermine> idk, didn't measure
<Ermine> good point though
<Ermine> you can try ddosing it
<heat> if its one of those web servers that spawn a process per client then you'd be trivially DDoS'd
zetef_ has joined #osdev
<Ermine> there are spawn limits
zetef_ has quit [Client Quit]
zxrom has joined #osdev
zetef has quit [Ping timeout: 255 seconds]
<Ermine> Ah, btw, I forgor one thing: crawlers do visit my site
<geist> robots.txt!
<Ermine> So actually maybe there's some traffic
goliath has quit [Quit: SIGSEGV]
ski has quit [Ping timeout: 255 seconds]
<Ermine> I'll lift restrictions and take a look at graphs
<heat> Ermine, hitting a spawn limit is still DDoSing
<heat> because no more requests will be served
<Ermine> then there's connection queue
<Ermine> which is inherent limitation of all web servers in existence
ski has joined #osdev
<geist> oh is this a server on your os?
<heat> Ermine, yes but it all depends on how many requests you can dispatch at a time, how quickly and how expensively
<heat> you can handle more threads than processes because processes are inherently expensive, even if you just fork and don't exec a new one
<Ermine> Yes
<heat> you can handle more requests quickly if you don't copy around data randomly using pipes with other 2 processes or so
<nikolar> You can always mmap if you need to
<Ermine> skarnet tried to squeeze everything he could out of this programming models. By using splice, posix_spawn, etx
<Ermine> etc*
<Ermine> I really want to see real data though
<heat> sure, but it'll inevitably be worse, even if you really try to squeeze it
<Ermine> But I think it won't be able to handle highload stuff
<Ermine> But then again, not everything in this world is highload
<heat> even the more normal method where you have a listening socket and a thread pool (or fully non-blocking IO like nodejs) breaks down on really *high* load stuff
<Ermine> And highload people use stuff suited for highload
<heat> yes, but the suckyness of that method is only mitigated by hardware being so damn fast
<Ermine> ... and by using a lot of hardware. Or CDNs
<heat> it's exactly like a microkernel, but in userspace
<heat> which is ironic because the unix philosophy people don't like em
<Ermine> Or by LEDBAT if you're releasing an AAA game
<heat> what is that?
<Ermine> one of unix philosophy variants advises microkernels, as per wikipedia
<Ermine> Afaik it's torrent-like stuff
<heat> i guess the unix philosophy people that believed in microkernels all went to plan9
<nikolar> Is that what they use to distribute updates from one machine to another on the same network
<Ermine> which was probably used for distributing Cyberpunk 2077 when it's was released
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
dude12312414 has joined #osdev
<Ermine> heat: plan9 people lol'd over microkernels
<Ermine> "our kernel is not microkernel but it's smol"
<nortti> < heat> even the more normal method where you have a listening socket and a thread pool (or fully non-blocking IO like nodejs) breaks down on really *high* load stuff ← what setup does work for the really high loads?
<Ermine> E B P F
<heat> yeah ebpf
<heat> or userspace network stacks, or both
<netbsduser> mach was distilled from unix
<nortti> so essentially removing the userspace - kernelspace distinction for the process?
<netbsduser> the mach port concept is the radicalisation of the FD
<nortti> except with more granularity
<heat> yep
<Ermine> nikolar: I guess the premise was that you don't want to transmit a fucking big game to every single customer
<heat> there's also a technique where you distribute requests per N (network) sockets and N cpus, based on hash, and then communication happens exactly on that CPU
<Ermine> (Hoyoverse doesn't do anything clever so you download Genshin Impact patches at ~250KB/s)
<heat> i know eBPF supports it, there's also some setsockopt stuff for that IIRC
<Ermine> Also probably I O _ U R I N G
<heat> yeah SO_REUSEPORT
<heat> i'm not sure if io_uring is seeing actual usage, i know google doesn't use them
<heat> and they also have a userspace stack, meta has a userspace stack too
<Ermine> Yeah data would be welcome
<Ermine> But kernel people utilize it for optimizing network stack itself
<Ermine> In HFT world people do kernel bypass btw
<heat> of course
<heat> there's also kernel bypass for storage, dpdk
<nortti> what is the NVMe programming interface, can you just memory map section of disk?
<heat> no
<Ermine> But then again, this is a world where you want to be as fast as possible and thus you're removing every obstacle possible
<nortti> how does the kernel bypass work then?
<heat> NVMe over PCIe is basically a ring buffer of submission entries and completion entries
<heat> well, submit the request and poll :)
<nortti> ah, yeah, that makes sense
<Ermine> For networking, afaik there are special nics and special apis for that
<heat> in linux you can also poll in the kernel these days
<heat> for both nics and storage
<Ermine> So anyway, this is not needed for humble smol low-tier VPSes here and there. But should the need arise, I'll pick more sophisticated (and more cursed) tools
<adder> heat: What should I figure out next?
<nortti> what do you have atm?
<adder> Loading gdt and idt, and handling interrupts by merely iretl, i.e., ignoring them.
<heat> well, handle them
<heat> panic on exceptions
<heat> it's important for debugging
<adder> Should panic just print out stuff?
<nortti> that's reasonable
<heat> yeah, error message, maybe some registers, and hang
gbowne1 has joined #osdev
<adder> Alright, thanks.
<heat> then get IRQs, see the 8259 PIC and PIT
CryptoDavid has joined #osdev
<adder> Okay.
melonai has quit [Quit: Ping timeout (120 seconds)]
melonai has joined #osdev
netbsduser has quit [Ping timeout: 264 seconds]
netbsduser has joined #osdev
GeDaMo has quit [Quit: That's it, you people have stood in my way long enough! I'm going to clown college!]
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
<kof673> > i think it might mean all things to all men well...everything eventually becomes that :D
<kof673> or, have to know: 1) what preceded it 2) what was peak 3) what was death to make any sense of it
ski has quit [Ping timeout: 260 seconds]
<kof673> *is/was death needs something to delineate and indicate what it is/was not
<kof673> *what preceded/was contemporary with
ski has joined #osdev
elderK has joined #osdev
<adder> Is there an easy way to see what's interrupting me? I guess I could define 256 routines each printing out its number, but this doesn't strike me like the proper way to go about it. I checked if it's 0x70, but it seems it's not.
<heat> >I guess I could define 256 routines
<heat> bingo.
<adder> Alright. :)
<Bitweasil> There's an awful lot of interrupt handlers that are "Set a value to indicate which vector it came in on, then go call the appropriate general handler."
<Bitweasil> But, yes, "set value from 0-255 in rax, call print handler" seems an entirely reasonable solution to the problem here.
<adder> No rax for me, yet.
<heat> push it to the stack
<adder> heat says it's too dangerous.
<adder> Yeah, that's what I'm doing.
<Bitweasil> [whatever register happens to be useful for it, wasn't sure what ISA you were in]
<heat> what is dangerous
<adder> I'm just joking that I'm not in long mode yet.
<heat> lol
<heat> anyway yeah push to the stack
<Bitweasil> *leans back in chair* "I, too, push values to the stack in my page fault handler!"
<heat> you should basically end up with 256 "isrN: push N; jmp generic_interrupt_handler"
<heat> but then you have to take into account that some exceptions have error codes and others dont
<heat> so you'll need a no_err_code variant that pushes a dummy value to the stack
<adder> Alright.
<heat> basically you want to have a strict "struct registers" thing that keeps all your exception state, and you'll keep that in the stack when entering the ISR handler
<adder> Wait, I'm not sure I understand. Some exceptions will have error codes I need pushed, some won't. This is where it branches into two routines, where one pushes the actual error code, and the other pushes a dummy value. Then, while still in the "generic" handler, I push all registers on the stack, so that any concrete isr has them on the stack before I jump there?
<bslsk05> ​github.com: Onyx/kernel/arch/x86_64/interrupts.S at master · heatd/Onyx · GitHub
<heat> i hope this helps
<heat> the IRQ and ISR_NOERRCODE could and should be collapsed, but technical debt
<adder> Cool, I'll study how this is done.
ski has quit [Ping timeout: 252 seconds]
<Mondenkind> 'sus microsystems'
<heat> sus microcrapper
Arthuria has quit [Killed (NickServ (GHOST command used by Guest684531))]
Arthuria has joined #osdev
cow321 has quit [Ping timeout: 268 seconds]
xFCFFDFFFFEFFFAF has joined #osdev
Turn_Left has joined #osdev
Arthuria has quit [Killed (NickServ (GHOST command used by Guest684531))]
Left_Turn has quit [Ping timeout: 256 seconds]
<adder> So, 8 hits me first, and then a bunch of 13s.
<heat> 8 is double fault, 13 is GPF
<heat> sounds like either your stack is screwed, your IDT is screwed, or your GDT is
<zid> qemu interrupt log is helpful here
CryptoDavid has quit [Quit: Connection closed for inactivity]
<Mutabah> second what zid said
<heat> minute what Mutabah said
<heat> hehehehehehe
<Mutabah> heat: huehuehue
Turn_Left has quit [Read error: Connection reset by peer]
<Ermine> sounds like 3 should be a triple fault