LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 04-22-2019, 08:58 AM   #1
shilimkarv
LQ Newbie
 
Registered: Apr 2019
Posts: 1

Rep: Reputation: Disabled
i2c mux using gpio pins


I have used https://lore.kernel.org/patchwork/patch/952860/ for getting sfp driver so that i can read SFP eeprom, SFP eeprom is connected over i2c bus. But there are multiple SFP's connected to address 0x50 and they are selected based on gpio select signal. I need dst structure for creating virtual i2c bus which will create device directory for all the sfp devices connected.

for example after using above patch i am using

echo optoe2 0x50 > /sys/bus/i2c/devices/i2c-0/new_device
echo port1 > /sys/bus/i2c/devices/i2c-0/port_name

to add the i2c device 0x50.

What i need is
/sys/bus/i2c/devices/i2c-0/0-0050
/sys/bus/i2c/devices/i2c-1/0-0050
.
.
multiple dummy i2c buses for each SFP eeprom.

so i have to modify the dts for the same. Any suggestions on that.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
BananaPro, WiringLMK, i2c and GPIO pins justwantin Slackware - ARM 3 01-18-2016 02:35 AM
LXer: Get started using the GPIO pins in RasPi issue 2! LXer Syndicated Linux News 0 09-12-2014 09:33 PM
LXer: Raspberry Pi GPIO pins the Python column LXer Syndicated Linux News 0 06-03-2014 11:16 PM
[SOLVED] Accessing GPIO-pins on a MPC8308E RDB (powerpc) Amys Linux - Embedded & Single-board computer 4 09-10-2010 07:52 AM
can i use I/o Port pins of a processor as four SPI pins? i sunr2007 Linux - Embedded & Single-board computer 3 08-20-2009 01:23 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 04:48 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration