**** BEGIN LOGGING AT Sun Jul 17 02:59:58 2016 Jul 17 17:13:51 alexhiam, Wormo There? I have some doubts? Jul 17 17:14:03 yeah, what's up? Jul 17 17:14:09 Hey alexhiam ! Jul 17 17:14:29 Please take a look here: http://invo-tronics.com/spi-driver-for-linux-based-embedded-system/ Jul 17 17:15:40 Here it talks about registering the SPI driver with the platform bus. I am getting confused whether this is done by the controller or the protocol driver Jul 17 17:16:43 alexhiam, And the steps given after that(till it starts talking about the protocol driver), do I need to follow them? Jul 17 17:16:57 are you looking at the omap spi driver as reference? Jul 17 17:17:58 Well I was looking at this and I got throughly confused:http://lxr.free-electrons.com/source/drivers/spi/spi.c Jul 17 17:17:59 alexhiam, Jul 17 17:20:01 alexhiam, Taking about this? http://lxr.free-electrons.com/source/drivers/spi/spi-omap2-mcspi.c Jul 17 17:20:50 yeah, or any other controller driver Jul 17 17:21:15 alexhiam, Okay I will take it as ref Jul 17 17:21:26 alexhiam, I am not using dma as of now. Jul 17 17:22:02 Just using ioremap to allocate memory and write. in the transfer function Jul 17 17:23:20 alexhiam, The char driver that I was writing was a success and it is working very well.m_w made a video :https://plus.google.com/+MichaelWelling79/posts/9feQenhHbbV Jul 17 17:24:05 awesome Jul 17 18:09:31 alexhiam, I have one more doubt about platform bus. mcspi uses it to talk to the hardware controller. But in my case, the PRU's internal memory can be accessed by the arm as a local address Jul 17 18:09:47 So I do need the platform bus. Jul 17 18:10:45 do I ? Jul 17 18:11:03 *So do I need it? Jul 17 18:12:23 All of the examples that I have seen use the platform bus as a virtual bus to bind the kernel to the hardware controller. Jul 17 18:12:27 Wormo, ^^ Jul 17 18:12:52 ds2^^ Jul 17 20:28:42 m_w, There? Jul 17 20:30:02 yup Jul 17 20:30:17 watching first season of mr.robot Jul 17 20:34:06 Ohh m_w I have also watch that. Though the only series that I have seen related to tech is Silicon Valley. Jul 17 20:34:30 :) Jul 17 20:34:36 It actually inspired me to look into compression techniques :P Jul 17 20:34:53 Direct Cosine Transform and stuff m_w :P Jul 17 20:37:13 how is the firmware progressing? Jul 17 20:37:14 m_w, Okay I just have one doubt that when I am registering as a platform driver, I have to also register the device according to this: https://lwn.net/Articles/448499/ Jul 17 20:38:32 So do I need to do this for the pru. Because I did not find any of this in the mcspi driver. Jul 17 20:39:42 you could use a registration for the memory offset for the shared memory instead of hardcoding it Jul 17 20:42:24 you should use devicetree registration Jul 17 20:43:30 m_w, So I have to code the resource array and then in its contents put the shared memory adressess in .start and .end Jul 17 20:43:32 Ohh Jul 17 20:44:38 the resources can be passed via devicetree entries Jul 17 20:45:26 Okay so the platform data can be taken from device tree entries?m_w? Jul 17 20:45:54 I did not that device tree entries could be called in code. Jul 17 20:48:04 For the moment can't I just write stuff manually in the resource table? Later when I get a device tree up I could replace them with device tree entries? Jul 17 20:48:08 m_w, ^? Jul 17 20:50:21 you should learn a bit more about how device tree and platform registration works Jul 17 20:51:17 Okay m_w . Working on it. Jul 17 20:52:02 And regarding the firmware, the code in all the cases is not the same. Actually the code for a particular case only depends upon the CPOL Jul 17 20:52:45 are you sure? Jul 17 20:53:50 0 and 1 are the same Jul 17 20:54:10 2 and 3 are the same Jul 17 20:54:32 m_w, Because I think the choice whether a device samples on the rising/falling edge does not concern us. Our code will generate the Jul 17 20:55:26 waveforms according whether the clock's active state is 0 or 1 . Jul 17 20:55:41 okay Jul 17 20:55:50 Rest when the device samples data is not really our problem in case of MOSI Jul 17 20:56:01 Yes in MISO, it will make a difference Jul 17 20:56:29 okay Jul 17 21:07:31 http://elinux.org/images/4/48/Experiences_With_Device_Tree_Support_Development_For_ARM-Based_SOC's.pdf Jul 17 21:08:15 Okay m_w . Will go through it. Jul 17 21:10:30 m_w, Just one more doubt that just popped in my head. When you say__R30=__R30(1<<14) Jul 17 21:10:54 So the 1 is followed by zeros right? Jul 17 21:11:23 Like 1 is left shifted and it is followed by zeros right? Jul 17 21:11:24 yeah Jul 17 21:11:50 Okay thanks . Jul 17 21:17:05 m_w, Do tell how mr. robot is. Watch silicon valley too. It's really nice Jul 17 21:17:16 Numb3rs was also very nice Jul 17 21:17:28 If someone is a math enthusiast :P Jul 17 21:17:58 I watched the whole series of numb3rs already Jul 17 21:18:07 did not last that long Jul 17 21:21:30 It was six seasons. That's pretty long m_w :P Jul 17 21:26:31 A lot of my friends watched here. Navi Rawat as Amita Ramanujan was awesome :P Jul 17 21:27:54 m_w, I don't know if you know, the character was inspired by a real life mathematician Srinivasan Ramanujan. **** ENDING LOGGING AT Mon Jul 18 02:59:58 2016