Re: Links and advice for new members

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
moonchild
Member
Member
Posts: 73
Joined: Wed Apr 01, 2020 4:59 pm
Libera.chat IRC: moon-child

Re: Links and advice for new members

Post by moonchild »

Schol-R-LEA wrote: [x86] is notoriously quirky, especially regarding Memory Segmentation, and the sharp divisions between 16-bit Real Mode, 16-bit and 32-bit Protected Modes, and 64-bit Long Mode.
You don't have to worry so much about real/protected mode or segmentation if you use uefi to go straight to long mode.
nullplan
Member
Member
Posts: 1792
Joined: Wed Aug 30, 2017 8:24 am

Re: Links and advice for new members

Post by nullplan »

moonchild wrote:You don't have to worry so much about real/protected mode or segmentation if you use uefi to go straight to long mode.
Agreed, but you still need to know about them, and you do still need to deal with the last remnants of segmentation either way (namely setting up a GDT, or else you cannot set up an IDT, or load the task register). Plus, even then, you need to deal with FS and GS base addresses.
BTW, other architectures do thread pointers simply by reserving a register for them. No need for any spooky kernel mode transition to change that value or anything.
Carpe diem!
User avatar
bzt
Member
Member
Posts: 1584
Joined: Thu Oct 13, 2016 4:55 pm
Contact:

Re: Links and advice for new members

Post by bzt »

Please remove SFS from your template, and recommend USTAR instead to newcomers. Reasons:
  • SFS is abadoned now.
  • The wiki page has insufficient information, nowhere near enough to actually implement a driver.
  • The spec on the wiki describes a format that's incompatible with other file systems, as it's about v1.0
  • It does not describe BenLunt's v1.10 version which addresses these issues (and is incompatible with v1.0).
  • Brendan's bcos.org is long gone, no official spec available
  • So is the other "official specification" where the wiki points to, combuster's page gives HTTP 404.
  • There's no multiplatform tool to create file system images, so you can't verify or check if your driver does comply with the spec at all. The link for the original (Windows-only) tool gives 404 too.
  • It never gained popularity, as far as I know, BOOTBOOT is the ONLY loader that ever bothered to implemented it.
USTAR on the other hand is standardized, well established, used by millions of people every day; and has a file system creator on all mainstream OSes that newcomers can use out-of-the-box. There are numerous Open Source libraries to deal with USTAR, it is supported by newlib too for example.

(Ps. I can understand that web.archive links work, but do we really recommend those on the wiki?)

Cheers,
bzt
PeterX
Member
Member
Posts: 590
Joined: Fri Nov 22, 2019 5:46 am

Re: Links and advice for new members

Post by PeterX »

I second that tar is a very good starting point for newbie FS-code writers.

What do you think about renaming the title USTAR to USTAR/tar?
It would make it more obvious that it is the same format the tool "tar" uses (which is mentioned in the second sentence, but anyway).

Greetings
Peter
User avatar
iansjack
Member
Member
Posts: 4703
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Links and advice for new members

Post by iansjack »

@bzt I'm concerned that you are perhaps being influenced by your past relationship with Brendan. You should certainly not be telling people what to post (although you might usefully suggest they consider something else).

Personally, I'd never suggest that anyone use any form of FAT. But I respect the right of others to suggest it.
User avatar
bzt
Member
Member
Posts: 1584
Joined: Thu Oct 13, 2016 4:55 pm
Contact:

Re: Links and advice for new members

Post by bzt »

iansjack wrote:@bzt I'm concerned that you are perhaps being influenced by your past relationship with Brendan. You should certainly not be telling people what to post (although you might usefully suggest they consider something else).
You can rest. I wanted to add SFS to my image creator, and I've faced the fact that there's no official specification available, the wiki page is insufficient to implement it, and I couldn't find any image creator that I could have used to create a reference image. That's why I suggested not to recommend it to newcomers.

Maybe SFS was started by Brendan, and like more members I might have had issues with that rouge moderator as well; however SFS was significantly improved by BenLunt and others, and I think of it as a community effort of this forum (the v1.10 version, not the v1.0 one, but I couldn't find any specification for v1.10 either).
iansjack wrote:Personally, I'd never suggest that anyone use any form of FAT. But I respect the right of others to suggest it.
I wouldn't recommend FAT either, but we must realize that it is THE file system for ESP, so we must support it whether we like it or not. It is also the de facto standard for file interchange, all mainstream OSes support it, and many devices (MP3 players, cameras, video recorders etc.) use that too for compatibility.

Cheers,
bzt
User avatar
Schol-R-LEA
Member
Member
Posts: 1925
Joined: Fri Oct 27, 2006 9:42 am
Location: Athens, GA, USA

Re: Links and advice for new members

Post by Schol-R-LEA »

I will leave SFS there for now (since I wasn't really making any specific recommendations), but I will add USTAR.
Rev. First Speaker Schol-R-LEA;2 LCF ELF JAM POEE KoR KCO PPWMTF
Ordo OS Project
Lisp programmers tend to seem very odd to outsiders, just like anyone else who has had a religious experience they can't quite explain to others.
User avatar
bzt
Member
Member
Posts: 1584
Joined: Thu Oct 13, 2016 4:55 pm
Contact:

Re: Links and advice for new members

Post by bzt »

Schol-R-LEA wrote:I will leave SFS there for now (since I wasn't really making any specific recommendations), but I will add USTAR.
Fine. But in this case may I ask you (or maybe BenLunt perphaps if he's willing to) to add an up-to-date and usable description on the wiki page? Right now it is insufficient (says by someone who tried to implement SFS using the said wiki page). I see no point in recommending something that's unimplementable and has no available FOSS tools.

Cheers,
bzt
User avatar
iansjack
Member
Member
Posts: 4703
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Links and advice for new members

Post by iansjack »

I haven't got a copy of the book, but doesn't Ben describe FYSFS in Vol.2 of his series (FYSOS: The Virtual File System)?
User avatar
bzt
Member
Member
Posts: 1584
Joined: Thu Oct 13, 2016 4:55 pm
Contact:

Re: Links and advice for new members

Post by bzt »

iansjack wrote:I haven't got a copy of the book, but doesn't Ben describe FYSFS in Vol.2 of his series (FYSOS: The Virtual File System)?
I don't know, I don't have it either, but it doesn't matter because Schol-R-LEA recommends the wiki page, not BenLunt's book. (And there's no link to that book on the wiki at all. Should be I think.)

FYI, I gave up on implementing SFS. If someone manages to create a v1.0 or v1.10 image somehow they should still be able to boot it with BOOTBOOT, but otherwise I've let SFS go. (In lack of a FOSS image creator I could do this because BenLunt was kind enough to provide me test images back then, which sadly got lost in the last couple of years...)

Cheers,
bzt
User avatar
eekee
Member
Member
Posts: 892
Joined: Mon May 22, 2017 5:56 am
Location: Kerbin
Discord: eekee
Contact:

Re: Links and advice for new members

Post by eekee »

Schol-R-LEA wrote:You need to consider what kind of File System to use. Common ones used when starting out in OS dev include:
I don't think I ever had any conflict with Brendan, but SFS doesn't fit the header of this list. ;) It's not commonly implemented at all, especially not by beginners. Perhaps that indicates the problems listed by bzt are real. For my part, I also thought the specification incomplete to the point where I wondered if it would be a good idea to take down the page. I struggle badly when information purports to be for beginners but omits or confuses crucial details. I wouldn't want to inflict that on other newcomers. Lesser grumbles I just noticed today: why is the superblock in the already overcrowded sector 0? It's small, but is there any reason it couldn't go in sector 1 or further in? Restricting the characters which may be used in a filename is a huge nuisance and unnecessary with a half-decent shell.
Kaph — a modular OS intended to be easy and fun to administer and code for.
"May wisdom, fun, and the greater good shine forth in all your work." — Leo Brodie
User avatar
pvc
Member
Member
Posts: 201
Joined: Mon Jan 15, 2018 2:27 pm

Re: Links and advice for new members

Post by pvc »

Is it just me or you are arguing about filesystem stuff in 'Links and advice for new members' thread ? Great example… great…
User avatar
eekee
Member
Member
Posts: 892
Joined: Mon May 22, 2017 5:56 am
Location: Kerbin
Discord: eekee
Contact:

Re: Links and advice for new members

Post by eekee »

Well maybe, but I'm really tired of bad advice.
Kaph — a modular OS intended to be easy and fun to administer and code for.
"May wisdom, fun, and the greater good shine forth in all your work." — Leo Brodie
klange
Member
Member
Posts: 679
Joined: Wed Mar 30, 2011 12:31 am
Libera.chat IRC: klange
Discord: klange

Re: Links and advice for new members

Post by klange »

I would prefer that this discussion not be tacked onto the stickied thread, so I have split it off and locked the original sticky.
Post Reply