*** tpb <[email protected]> has joined #litex | 00:00 | |
DerekKozel[m] | The GNU Radio blocks are achieving 7.22 Gbps throughput over Thunderbolt, same as the litepcie_util dma_test. Might improve that when this moves read/write to separate threads this weekend. | 00:11 |
---|---|---|
DerekKozel[m] | _florent_: You suggested changing the pcie DMA buffering_depth to 8k last time we talked about throughput. What do you think about adding that parameter to add_pcie()? | 00:13 |
DerekKozel[m] | https://github.com/enjoy-digital/litex/blob/master/litex/soc/integration/soc.py#L1720 | 00:13 |
DerekKozel[m] | If thumbs up I can do that PR | 00:13 |
*** Degi_ <[email protected]> has joined #litex | 02:35 | |
*** Degi <[email protected]> has quit IRC (Ping timeout: 260 seconds) | 02:36 | |
*** Degi_ is now known as Degi | 02:36 | |
cr1901 | _florent_: When you get the chance, could you run " python3 -m litex_boards.targets.1bitsquared_icebreaker --cpu-type=serv --build --flash" and report back w/ whether the SoC runs? I cannot get a working firmware, but the gateware seems fine | 04:20 |
cr1901 | readelf -A build/1bitsquared_icebreaker/software/bios/bios.elf | 04:20 |
cr1901 | Tag_RISCV_arch: "rv32i2p0" | 04:20 |
cr1901 | This looks fine too | 04:21 |
cr1901 | I can duplicated the SoC not working on both Linux and Windows. So I don't think it's a cosmic ray event | 04:21 |
mc6808 | _florent_: I just bisected liteeth: 2b23788 works and 43a2ea8 fails with litescope -v ... . https://github.com/enjoy-digital/liteeth/commit/43a2ea811819c4fa07e9b5db996a58ae8bc5db5d | 05:54 |
mc6808 | _florent_: I guess this is marginal timing with gigE on ECP5? | 05:57 |
mc6808 | Warning: Max frequency for clock '$glbnet$etherbone_clk': 68.07 MHz (FAIL at 75.01 MHz) | 05:57 |
mc6808 | Warning: Max frequency for clock '$glbnet$eth_clocks_rx$TRELLIS_IO_IN': 110.47 MHz (FAIL at 125.00 MHz) | 05:57 |
mc6808 | Info: Max frequency for clock '$glbnet$init_clk': 362.32 MHz (PASS at 25.00 MHz) | 05:57 |
mc6808 | Info: Max frequency for clock '$glbnet$clk100$TRELLIS_IO_IN': 410.00 MHz (PASS at 100.00 MHz) | 05:57 |
mc6808 | Info: Max delay <async> -> <async> : 0.15 ns | 05:57 |
mc6808 | Info: Max delay <async> -> posedge $glbnet$etherbone_clk : 3.79 ns | 05:57 |
mc6808 | Info: Max delay <async> -> posedge $glbnet$init_clk : 3.20 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$clk100$TRELLIS_IO_IN -> posedge $glbnet$etherbone_clk : 4.29 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$clk100$TRELLIS_IO_IN -> posedge $glbnet$init_clk : 3.69 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$eth_clocks_rx$TRELLIS_IO_IN -> <async> : 6.97 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$eth_clocks_rx$TRELLIS_IO_IN -> posedge $glbnet$etherbone_clk : 1.29 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$etherbone_clk -> <async> : 10.61 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$etherbone_clk -> posedge $glbnet$eth_clocks_rx$TRELLIS_IO_IN: 2.94 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$etherbone_clk -> posedge $glbnet$init_clk : 2.33 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$init_clk -> <async> : 3.28 ns | 05:57 |
mc6808 | Info: Max delay posedge $glbnet$init_clk -> posedge $glbnet$etherbone_clk : 1.68 ns | 05:57 |
*** TMM_ <[email protected]> has quit IRC (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) | 05:58 | |
*** TMM_ <[email protected]> has joined #litex | 05:58 | |
*** Guest78 <[email protected]> has quit IRC (Quit: Client closed) | 06:39 | |
*** tnt_ <tnt_!~tnt@osmocom/tnt> has joined #litex | 07:00 | |
*** shenki_ <[email protected]> has joined #litex | 07:00 | |
*** peepsalot <peepsalot!~peepsalot@openscad/peepsalot> has quit IRC (Remote host closed the connection) | 07:01 | |
*** peepsalot <peepsalot!~peepsalot@openscad/peepsalot> has joined #litex | 07:02 | |
*** vomoniyi[m] <vomoniyi[m]!~vomoniyig@2001:470:69fc:105::3023> has quit IRC (Ping timeout: 260 seconds) | 07:09 | |
*** tnt <tnt!~tnt@osmocom/tnt> has quit IRC (Ping timeout: 260 seconds) | 07:09 | |
*** shenki <[email protected]> has quit IRC (Ping timeout: 260 seconds) | 07:09 | |
*** willcode4[m] <willcode4[m]!~willcode4@2001:470:69fc:105::e1b3> has quit IRC (Ping timeout: 260 seconds) | 07:09 | |
*** vomoniyi[m] <vomoniyi[m]!~vomoniyig@2001:470:69fc:105::3023> has joined #litex | 07:13 | |
*** willcode4[m] <willcode4[m]!~willcode4@2001:470:69fc:105::e1b3> has joined #litex | 07:16 | |
_florent_ | DerekKozel[m]: We should indeed expose more parameters to add_pcie, happy to review/merge the PR if you look at it. | 07:41 |
*** tnt_ is now known as tnt | 07:42 | |
_florent_ | cr1901: It's working here yes, here is the fpga bitstream + bios if you want to check your hardware with it: https://github.com/litex-hub/litex-boards/files/7379097/1bitsquared_icebreaker_fpga%2Bbios_2021_10_20.zip | 07:42 |
_florent_ | mc6808: Thanks for looking at it, I opened https://github.com/enjoy-digital/liteeth/issues/86 for this, I'll look at this and will do tests on ECP5 and others FPGAs to see if it's ECP5 specific. | 07:45 |
_florent_ | mntmn: For the framebuffer/color issue, you could eventually use the colorbars pattern to investigate more easily by replacing the framebuffer with something like this: https://github.com/litex-hub/litex-boards/blob/5190c9c869ad61c9940a8b8a766b6808382e934c/litex_boards/targets/sipeed_tang_nano_4k.py#L114-L115 | 07:48 |
*** ewen <[email protected]> has joined #litex | 08:15 | |
_florent_ | DerekKozel[m], ilia__s: The OpenOCD modification discussed yesterday has been pushed to https://github.com/enjoy-digital/openocd | 08:32 |
*** C-Man <[email protected]> has quit IRC (Ping timeout: 265 seconds) | 08:32 | |
_florent_ | I also created https://github.com/enjoy-digital/litex/wiki/FPGA-and-SPI-Flash-programmers to clarify installation of programmers | 08:32 |
ilia__s | _florent_: why should not this patch be contributed to openocd master? | 08:33 |
DerekKozel[m] | Thanks florent | 08:34 |
DerekKozel[m] | I really appreciate your time here. I'm collecting general notes and will find places for them in the wiki. | 08:36 |
DerekKozel[m] | Do you have any ICAP references or snippets for host to FPGA loading? I found the antmicro code and examples for loading from the softcore. | 08:39 |
_florent_ | ilia__s: This would be done yes, I haven't spent the time yet to understand the OpenOCD upstream process, this was just the path of least resistance... | 08:45 |
_florent_ | DerekKozel[m]: I haven't used ICAP for this yet but plan to do so soon, I was also going to look at antmicro's code | 08:47 |
DerekKozel[m] | Ok. not a priority, just a nice to have | 08:47 |
*** ewen <[email protected]> has quit IRC (Ping timeout: 260 seconds) | 09:23 | |
*** futarisIRCcloud <[email protected]> has joined #litex | 09:25 | |
futarisIRCcloud | https://twitter.com/UlfFrisk/status/1450752076552757251 | 09:26 |
_florent_ | futarisIRCcloud: Thanks for sharing, that's interesting. Since the Acorn has 4 GTP lanes and only one is used by PCIeLeech, it would also be possible to use one of the other lanes for the communication with the Host, like USB3. | 09:49 |
_florent_ | This would be a nice usecase of the https://github.com/enjoy-digital/usb3_pipe or Luna, but there is still a bit of work to do to have something usable | 09:50 |
*** C-Man <[email protected]> has joined #litex | 09:53 | |
cr1901 | _florent_: Thank you for the code... your code does not work either. Hmmm, I have a theory... what revision icebreaker do you have? | 10:20 |
cr1901 | Mine is v1.0b | 10:21 |
_florent_ | v1.0e | 10:22 |
cr1901 | I wonder if the SPI flash is different between v1.0b and e | 10:22 |
cr1901 | and that they need different parameters | 10:22 |
cr1901 | cc: esden is this possible? | 10:23 |
tnt | yes | 10:25 |
cr1901 | I can't find a schematic of "e" to confirm | 10:26 |
tnt | https://github.com/YosysHQ/icestorm/pull/283/commits/6a554eb70fd71459165c9bc1c9939c98a651995d | 10:26 |
cr1901 | >if you used the wrong flash chip | 10:28 |
cr1901 | Can you elaborate? :P | 10:28 |
tnt | There is a bunch of different variants of the windbond 25q128 depending on the letters after the part number. | 10:29 |
tnt | After power up, some have QE=1, some have QE=0. The litex spi flash thing doesn't do any init and so doesn't write the flash mode register to properly set it, it assumes it's all ready. Which depending on the defaults, it might not be. | 10:30 |
cr1901 | Shit, I'd rather just have 1-bit width mode than go through this | 10:31 |
cr1901 | tnt: Thank you for your patch of course :) | 10:31 |
tnt | I'm assuming your part number ends in 'IM' on the flash ? and not 'IQ' ? | 10:32 |
* cr1901 gets a flashlight | 10:32 | |
tnt | 2-bit width mode should work too without that bit set. (assuming the litex core suports that). | 10:32 |
tnt | You could also add support for init sequence to the litex core :D | 10:33 |
cr1901 | 25q128jvsm | 10:33 |
tnt | Yup. | 10:33 |
tnt | Note that I think the description of the patch is incorrect. There is a non-volatile version of that bit that's apparently OTP writable. | 10:34 |
cr1901 | >You could also add support for init sequence to the litex core :D | 10:35 |
cr1901 | That would be more ideal I think | 10:35 |
cr1901 | with that being said, I just wanted something that works b/c it's been a while since I've followed litex | 10:35 |
cr1901 | I had this problem w/ TinyFPGA Bx/B2 a long time ago... I hardcoded the wrong SPI flash parameters and I didn't understand the problem until Luke pointed it out. Months later. | 10:40 |
mntmn | if i use platform.add_verilog_include_path and platform.add_source_dir in a target, do i have to anything else with those files to get them to be picked up during a linux-on-litex-vexriscv build? | 11:02 |
mntmn | ah i see that the include paths are expected to be relative to linux-on-litex-vexriscv | 11:03 |
mntmn | not the target... | 11:03 |
cr1901 | gatecat: If I get an error like "ERROR: Bel 'X23/Y0/io0' of type 'SB_IO' is not valid for cell 'SB_IO_1' of type 'SB_IO' | 11:03 |
cr1901 | 0 warnings, 1 error", is there a verbose mode that'll tell me why without recompiling to enable the debug output? | 11:03 |
cr1901 | Nothing looks odd to me viewing it in the GUI, but I'm not very familiar w/ ice40 internals | 11:04 |
mntmn | yeah, that made it work | 11:04 |
gatecat | cr1901: there's no debug at all for validity checking failures atm :/ | 11:06 |
gatecat | it's probably to do with which IO tiles share a clock between two pins | 11:06 |
cr1901 | Ahhh hmmm. Guess I'm not getting around looking into this deeply lol | 11:08 |
tnt | Check what's at X23/Y0/io1 | 11:08 |
cr1901 | It's an I/O port | 11:09 |
tnt | yeah ... the `io1` was a big clue. | 11:09 |
tnt | I meant what you connected there. | 11:09 |
cr1901 | Oh, I already blew away those files... hang on... | 11:09 |
tnt | up5k ? | 11:09 |
cr1901 | yes | 11:09 |
tnt | So that's miso and mosi | 11:10 |
tnt | weird, I'd expect those to have compatible IO registers. | 11:10 |
cr1901 | I changed "self.add_spi_flash(mode="1x", module=W25Q128JV(Codes.READ_1_1_4), with_master=False)" to | 11:10 |
cr1901 | "self.add_spi_flash(mode="1x", module=W25Q128JV(Codes.READ_1_1_1), with_master=False)" just to see what would happen | 11:11 |
tnt | Not sure what's that supposed to do TBH. | 11:11 |
tnt | But I'd be interested to see the generated verilog. | 11:11 |
cr1901 | http://gopher.wdj-consulting.com:70/store/_1bitsquared_icebreaker.v | 11:13 |
cr1901 | http://gopher.wdj-consulting.com:70/store/_1bitsquared_icebreaker.json | 11:13 |
cr1901 | line 9789 for the offending I/O connection in json | 11:14 |
cr1901 | tnt: Btw, how'd you know it was MOSI/MISO so fast w/o a JSON? :o | 11:14 |
tnt | Ah yeah ... it's an invalid clock config technically. | 11:15 |
tnt | Because from the IO site I could get the pad number for the up5k and those were the flash is. | 11:15 |
cr1901 | ahhh, fair | 11:16 |
tnt | So technicaly SB_IO_1 is configured for registerd input. That's what the "PIN_MODE" sets it to. | 11:16 |
tnt | Even though the input path is not actually used. | 11:16 |
tnt | But if it's configured for registered input, then the INPUT_CLK must match ... and here obviously it doesn't since INPUT_CLK is not connected. | 11:17 |
tnt | if input isn't used, pin_type should be set to unregistered input mode. | 11:18 |
cr1901 | the INPUT_CLK must match _what_? | 11:18 |
cr1901 | Just... being connected is a "match"? | 11:18 |
tnt | must match what's in the other SB_IO that's in the same IO tile. | 11:19 |
tnt | which is SB_IO_2 here. | 11:19 |
tnt | There are two SB_IO per IO tile. And they must share clock_enable / input_clk / output_clk. | 11:20 |
cr1901 | Ahhh okay, and in this case | 11:20 |
cr1901 | INPUT_CLK is used on one, OUTPUT_CLK is used on the other | 11:20 |
tnt | yes. | 11:20 |
cr1901 | but not both | 11:20 |
cr1901 | And a way around this is to set the PIN_TYPE on one of the I/O pins to shut up the validity checker? | 11:21 |
tnt | And nextpnr looks at the PIN_TYPE to know if the register is used at all. | 11:21 |
cr1901 | set the PIN_TYPE appropriately* | 11:21 |
tnt | if it's not used, then it will ignore mismatched clock connection and just use the clock of the one that's effectively enabled. | 11:21 |
tnt | yes, setting pin_type to 21 should do it. | 11:22 |
cr1901 | >just use the clock of the one that's effectively enabled. | 11:23 |
cr1901 | "effectively" enabled? | 11:23 |
cr1901 | Anyways I get it now | 11:23 |
cr1901 | LiteX generates the SB_IOs, so I have to look there | 11:23 |
tnt | yeah, I mean image you feed INPUT_CLK(clk1) to one SB_IO and INPUT_CLK(clk2) to the other SB_IO. But then you have the pin_type set to unregistered input for the first one, it will use clk2 automatically and ignore the ck1 connection. | 11:24 |
tnt | (IIRC .. I wrote that a long time ago) | 11:25 |
cr1901 | ahhh neat | 11:25 |
cr1901 | tnt: Thanks for the explanation, I haven't really looked at ice40 internals. They're... different compared to ECP5/MachXO2 | 11:31 |
tnt | I'm re-reading that code and I'm wondering if I didn't screw up there ... I see the part that ignores the conflict if the register isn't needed. But I'm not sure where it picks the "right" net. It might just pick randomly :/ | 11:33 |
*** futarisIRCcloud <[email protected]> has quit IRC (Quit: Connection closed for inactivity) | 11:35 | |
tnt | ok, nm what I said above. It won't pick automatically. If it's not used, it needs to either match or be non-connected. | 11:35 |
mntmn | _florent_: i'm trying to understand the usb_ohci host. if i understand correctly the actual OHCI impl is included as verilog from something generated with spinalHDL? (spinal.lib.com.usb.ohci.UsbOhciWishbone) | 12:00 |
*** FabM <FabM!~FabM@armadeus/team/FabM> has quit IRC (Ping timeout: 252 seconds) | 12:09 | |
mntmn | is there an example for using Wishbone2AXILite and friends to integrate an AXI4Lite peripheral in linux-on-litex-vexriscv? | 12:58 |
mntmn | hmm there's also add_adapter in soc.py | 13:18 |
mntmn | ok, this seems to work: usb_wb = self.bus.add_adapter("usb_axi_wb", usb_axi) | 13:35 |
mntmn | but how do i set the address for the converted axi->wb peripheral? | 13:36 |
*** FabM <[email protected]> has joined #litex | 13:45 | |
mntmn | is there a multi-bit version of SDRTristate? | 14:07 |
mntmn | i mean, i have a 8 bit bidi bus with 1 dir bit | 14:07 |
mntmn | ah, migen Instance("Tristate") can do this | 14:11 |
mntmn | i'm trying to connect an Instance()'s axi4lite signals directly to an AXILiteInterface's axi.aw.*, w.*, r.* and so on signals... this fails in synthesis because there are registers missing in between, i think | 14:30 |
mntmn | the axi signals on the Instance() are all wires | 14:31 |
mntmn | i'm getting a bunch of errors like > procedural assignment to a non-register main_r_payload_data is not permitted | 14:31 |
mntmn | ok, possibly i had to specify "s2m" instead of "m2s" for the adapter | 14:47 |
mntmn | now i get > module 'Tristate' not found | 14:47 |
mntmn | ok, solved this too | 14:49 |
*** FabM <FabM!~FabM@armadeus/team/FabM> has quit IRC (Quit: Leaving) | 14:54 | |
*** mc6808 <[email protected]> has quit IRC (Quit: Client closed) | 17:40 | |
*** TMM_ <[email protected]> has quit IRC (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) | 19:19 | |
*** TMM_ <[email protected]> has joined #litex | 19:19 | |
_florent_ | mntmn: Sorry I was away, good if you managed to do what you wanted | 20:00 |
mntmn | _florent_: no problem! i came quite far. currently my problem is that the AXI4Lite interface of the core_usb_host wants to be the same 60mhz input clock coming in from the ULPI PHY, but my sys clk is 100MHz. i'm not sure if i have to do anything special to allow this clock crossing (i.e. 100mhz wishbone <-> 60mhz axi4lite) | 20:03 |
mntmn | _florent_: when i was supplying the core_usb_host with the sysclk, i was able to talk to it (via wishbone->axi4lite). now i connected the ulpi clock instead and it doesn't reply i think (all 0xff). it could also be that the ULPI clock is not running. i would need litescope or some counter to check this, i guess. | 20:05 |
mntmn | _florent_: in case you're curious, this is how my target looks like atm https://gist.github.com/mntmn/44c3396eb4935e36d91eac41e7bd02bf | 20:10 |
_florent_ | mntmn: You could probably use the AXILiteClockDomainCrossing for this | 20:36 |
_florent_ | https://github.com/enjoy-digital/litex/blob/master/litex/soc/interconnect/axi.py#L1075 | 20:36 |
mntmn | _florent_: i see | 20:36 |
_florent_ | the slave would be the bus connected to the usb core (running at 60MHz) and master the bus that will be connected to the SoC | 20:36 |
mntmn | _florent_: the master is wishbone in this case though, or created by add_adapter? | 20:38 |
_florent_ | BTW, you can directly add an AXILite peripheral with add_slave | 20:38 |
_florent_ | LiteX will automatically insert the adapter if required | 20:38 |
mntmn | oh! | 20:39 |
_florent_ | (ie converting to Wishbone for a SoC with a Wishbone bus) | 20:39 |
_florent_ | it can also automatically adapt the data-width | 20:39 |
mntmn | but how would i insert the AXILiteClockDomainCrossing in this case? | 20:39 |
mntmn | i mean because AXILiteClockDomainCrossing does not wrap a slave, but wants master and slave as arguments... it looks to me like they should not already be connected | 20:40 |
_florent_ | Something like this: | 20:44 |
_florent_ | https://www.irccloud.com/pastebin/kugsdJRV/ | 20:45 |
tpb | Title: Snippet | IRCCloud (at www.irccloud.com) | 20:45 |
_florent_ | then just use usb_axi_usb as you were doing with usb_axi | 20:45 |
mntmn | _florent_: ohh, i see. thanks a lot | 20:45 |
_florent_ | and just remove the usb_wb | 20:45 |
mntmn | yep | 20:47 |
nickoe | Hello guys and girls, it has been a long time I played around with litex now. Any news or changes I shoudl be awere of if I syncanew? | 20:57 |
_florent_ | Hi nickoe, you can find the list of the important changes here: https://github.com/enjoy-digital/litex/blob/master/CHANGES | 21:01 |
_florent_ | otherwise, a recent change is the switch to picolibc, you can look at https://github.com/enjoy-digital/litex/issues/1045 if issues related to this | 21:02 |
nickoe | Ok, thank you. | 21:12 |
* nickoe also needs to check if I am involved in any open issues | 21:12 | |
nickoe | _florent_: I remember I had in endianness issue with litex sim and som sdram, did you solve that somehow? | 21:21 |
nickoe | mm, I can't find it in my notes.. I guess I may stuble on it later if it is still a thing | 21:31 |
nickoe | ohh, I found it, it was on th elitedram repo https://github.com/enjoy-digital/litedram/issues/251 | 21:33 |
nickoe | _florent_: Is there something I can do to rectivy this mismatch? | 21:33 |
nickoe | *rectify | 21:33 |
*** toshywoshy <toshywoshy!~toshywosh@ptr-377wf33o3bnthuddmycb.18120a2.ip6.access.telenet.be> has joined #litex | 21:43 | |
nickoe | LiteX support for programming the flash via JTAG? | 21:46 |
nickoe | Reading XAPP586 it appears that ISE/IMPACT flashes a custom bitstream to the FPGA to route through the SPI mode from the JTAG to sprogram it? | 21:46 |
nickoe | It does appear as if lxterm did support programming the flash, but it was removed in this commit: https://github.com/enjoy-digital/litex/commit/41964f945cee71337e8e0998d597086b2ef94f77 How does one go about to program the flash now? | 21:46 |
nickoe | Does the netv2 support it? https://github.com/enjoy-digital/netv2/blob/14905f90ffdefadc396f2a1df8675d59ee151516/netv2.py#L227-L229 | 21:46 |
nickoe | I am slightly confused by this. | 21:46 |
nickoe | Other references: https://marc.info/?l=openocd-development&m=151002052505567&w=2 | 21:46 |
tpb | Title: 'Re: [OpenOCD-devel] artix-7 + spi flash programming' - MARC (at marc.info) | 21:46 |
ilia__s | sure litex does support flashing spi memories through jtag in various ways, depends on the fpga vendor and accordingly available programmers | 22:04 |
*** mc6808 <[email protected]> has joined #litex | 22:05 | |
ilia__s | this is for instance how it is handled through vivado: https://github.com/enjoy-digital/litex/blob/master/litex/build/xilinx/programmer.py#L157 | 22:06 |
ilia__s | here - through openfpgaloader: https://github.com/enjoy-digital/litex/blob/master/litex/build/openfpgaloader.py#L28 | 22:06 |
ilia__s | etc | 22:06 |
Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!