« first day (3582 days earlier)      last day (1372 days later) » 

4:11 AM
Certain country (Germany) has 8000+ active Covid-19 cases, recently it had massive protest with up to 20,000 turned up. Certain state (Victoria, Australia) with similar area, has 7000-8000 active Covid-19 cases and is imposing curfew between 8pm-5am with all entertainment outside homes banned.
Far right and far left are equally dumb, someone said & I agree.
 
 
2 hours later…
6:09 AM
So, anybody up to anything fun?
 
user7659542
6:27 AM
@TelKitty Oh so Antwerp in Belgium is not the only country to impose a curfew?
 
user7659542
@Mikhail yhea going to a wedding tomorrow, we ll be 400 people
 
user7659542
and then we ll hit the club and get mortal
 
8:28 AM
We're still doing the COVID thing
 
user7659542
COVID? Who is that guy?
 
user7659542
Some new type of webdev framework?
 
user7659542
@Mikhail it looks happy
 
I'm surprised the capacity didn't' change
 
user7659542
8:37 AM
it has always been capable of smiling
 
No I mean in TB
if you stretch stuff it should hold more bytes!
 
user7659542
@Mikhail indeed
 
^ Attending a wedding of 400 people during COVID-19 pandemic :x
 
user7659542
8:53 AM
then going to the nightclub and grinding with everybody, will be lit
 
9:09 AM
Apparently Unibroue (La Fin Du Monde) is owned by Sapporo. Is this Kurt Vonnegut's army of invasion or some other kind of Hocus Pocus?
 
user7659542
9:23 AM
do all CPUs only have one PCI(e) connection/bus?
 
user7659542
I hope not...
 
what?
 
@traducerad depends on your definition, some have non PCI(e) busses too that connect to the chipset that has additional PCI(e) lanes
 
user7659542
well I see people writing drivers and using the accessor functions ioread8 iowrite8
 
user7659542
and was wondering "how many PCI busses does this CPU have? If it is more than 1 they have to somehow specify on which bus the read/write operation shoudl happen"
 
9:28 AM
doesn't that just get defined by the addresses?
 
user7659542
afaik, you put the address of the PCI slave on the bus
 
user7659542
this does not tell you which one of your pci lanes you want to use
 
I meant can't the CPU just segment addresses to the different busses?
 
user7659542
imagine you have 2 slaves with the same address. Only solution to be able to use both of them is to have 2 physically different PCI busses and put each one on a different bus. You ll then have to specify somehow somewhere I want to write this on bus A or B
 
user7659542
@PeterT hmm, interesting. Dunno
 
9:31 AM
but why would you want to introduce that distinction? if you already have that indirection with the memory address mapping?
 
Also that isn't the only solution, in multisocket systems you have the CPUs sharing the bus but each getting different lanes.
 
just let the cpu deal with it or write it once on initialization during the memory layout setup, so that you don't have to make those very specific distinction all over your kernel
 
user7659542
because not everything is memory mapped afaik. I/O port access is I think not memory mapped. When you re in kernel space you write the physical address of the slave on the bus
 
it's not virtual memory mapped, doesn't mean that it can't be mapped otherwise, does it?
 
user7659542
hmm, maybe
 
9:34 AM
You're correct BUT if memory serves me correctly, it is considered best practices to use functions that pretend everything is memory mapped. AKA ioport_map
 
user7659542
dunno, all this memory mapping and i/o port access is still a bit vague and complex to me I notice
 
user7659542
I d need to read more about it to have a deeper understanding
 
user7659542
AFAIK there are only two address spaces (I might be wrong):

- virtual address space: a process has 2 virtual adress spaces. It is in this address space that it can access its stack variables etc... One address space in user space and one address in kernel space

- memory mapped I/O address space: whenever you eg want to set/clear a pin. You need to first memory map this pin (using ioremap). What this means is that you allocate extra memory in you virtual address space which directly maps to that piece of hardware. It is I think typically a chunk right next to your virtual memory so that yo
 
@traducerad I didn't say you have to map it, I think in some cases like for Intel they have a "system Agent" that does the mapping and negotiation with the DMI and PCIe busses
 
user7659542
then you have these accessor functions ioread8/iowrite8 and friends which you have to use when dealing with direct I/O, not mem mapped I/O
 
9:39 AM
so you have a physical address, but that address can still get mapped by the System Agent and/or the PCH
 
user7659542
mkay
 
@traducerad FYI, take a look at ioport_map
 
user7659542
Actually the wikipedia article is quite good:
 
user7659542
Memory-mapped I/O (MMIO) and port-mapped I/O (PMIO) (which is also called isolated I/O) are two complementary methods of performing input/output (I/O) between the central processing unit (CPU) and peripheral devices in a computer. An alternative approach is using dedicated I/O processors, commonly known as channels on mainframe computers, which execute their own instructions. Memory-mapped I/O uses the same address space to address both memory and I/O devices. The memory and registers of the I/O devices are mapped to (associated with) address values. So when an address is accessed by the CPU, it...
 
user7659542
9:56 AM
The wikipedia seems however to contradict the LWN page
 
user7659542
Wikipedia states that port mapped I/O uses "a special class of CPU instructions designed specifically for performing I/O, such as the in and out instructions found on microprocessors based on the x86 and x86-64 architectures"
 
user7659542
While it omits to specify such information when speaking about memory mapped I/O. I'd infer from this that when dealing with mem mapped IO one does not use such accessor functions.
 
user7659542
Yet, when reading LWN, they state "The readX() function does MMIO reads", implying memory mapped IO uses accessor functions too
 
> There is actually one other twist to these functions. Some drivers have to be able to use either I/O memory or I/O ports, depending on the architecture and the device. Some such drivers have gone to considerable lengths to try to avoid duplicating code in those two cases. With the new accessors, a driver which finds it needs to work with x86-style ports can call:
so, what Mikhail said
 
user7659542
@PeterT I don't get the point you re making :(
 
user7659542
10:04 AM
I understand every single word of your sentence, but don't see what message you re trying to convey
 
that clearly states that ioread8 does deal with port IO too
 
user7659542
oh
 
user7659542
never said it didn't
 
user7659542
wikipedia kinda seems to imply it is the other way around actually. That accessors are only for port mapped stuff
 
right, for mmio you can typically use normal instructions like with any other memory
 
user7659542
10:06 AM
int foo = 55;
 
user7659542
right?
 
sure, but they're refering to asm instructions, not C or C++
 
user7659542
Is it correct to say that: every device which is on a PCI/PCIe/ISA bus works via port mapping
 
user7659542
and all the rest via mem mapping?
 
I don't think that can be universally stated
 
user7659542
10:07 AM
how do you actually know which one you need?
 
there's PCI implementations for ARM and PPC and other too, not just x86
 
user7659542
How am I as a dev, supposed to know whether I have to use memory mapping or port mapping?
 
user7659542
@PeterT Does this mean that eg on x86 PCI uses port mapping but on ARM mem mapping?
 
I'm not familiar with that, but I don't see why it couldn't be implemented differently on other architectures
 
 
3 hours later…
12:44 PM
Why is 16 itoa is supported by some compilers but not the others?
 
weird I never looked into it, apparently all bases from 2-36 are supported, neat
presumably latin alphabet + 10 digits
 
I meant 'why is itoa is supported by some compilers but not others.' Mistyped.
16
A: gcc error : undefined reference to `itoa'

P.Pitoa is a non-standard function which is supported by some compilers. Going by the error, it's not supported by your compiler. Your best bet is to use snprintf() instead.

 
apparently it's not ANSI C and not C++ (before C99 compat)
 
1:10 PM
@TelKitty any reason you can't use std::to_string or std::to_chars?
 
1:30 PM
I am writing C code, so ..
 
oh my condolences
 
C is fine for communication part. Quite efficient.
 
eh I'd use C++ because I'm lazy insofar as the compiler for the target isn't complete crap
 
 
4 hours later…
5:27 PM
 
user7659542
6:25 PM
Do you know wy Pavlov's hair is so soft?
 
user7659542
Because he conditions it.
 
7:29 PM
What's Skorbut?
 
8:08 PM
yay,a link to a GitHub repo
oh, it's that thing
 
 
1 hour later…
9:18 PM
Eeeeeh
My old code seems better than the one I took so much time to steal
I've still got ways to improve both and I really have to improve the benchmarks too
But so far it's slightly disappointing
 
user1804599
Wazzap
 
user1804599
Hopefully I can fabricate synthesizer tomorrow.
 
But can you synthesize fabricator
 
user1804599
My EEPROM, DAC, and multiplexer will arrive.
 
@Mysticial you probably already saw this but massive leak from intel and they appear to have acknowledged it.
 
user1804599
9:35 PM
Nice.
 
user1804599
IP leaks are good. Lol IP.
 
11:15 PM
Did they find any interesting backdoors? Does Intel123 unlock the ME?
 

« first day (3582 days earlier)      last day (1372 days later) »