title: I2C Mux on Linux
body: <p>I am trying to understand how to address devices behind <code>I2C Mux</code> like <code>PCA9548</code> in <code>linux</code>.
  If the topology is something like</p>
  
  <pre><code>CPU-&gt;I2C_A Controller-&gt;PCA9548-&gt;Channel 0-&gt;RTC
  CPU-&gt;I2C_A Controller-&gt;PCA9548-&gt;Channel 1-&gt;Temp Sensor
  
  CPU-&gt;I2C_B Controller-&gt;PCA9548-&gt;Channel 0-&gt;Voltage Sensor
  CPU-&gt;I2C_B Controller-&gt;PCA9548-&gt;Channel 1-&gt;Speed Sensor
  </code></pre>
  
  <p>I want to know the representation of these devices in user space? What are the associated sysfs entries?</p>
  
  <p>I also want to know if <code>pc9548</code> is the only driver required in kernel and <code>i2c-dev</code> and <code>i2c-core</code> are already available? Or driver for RTC/sensors is also required?</p>
  
  <p>I have tried to read <a href="https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/drivers/i2c/i2c-mux.c?id=51cf3b0e2a72bb08cd280be6c0ead4e08ed50a2c" rel="nofollow">this</a>, but could not follow it much.</p>
  
  <p>My requirement is to read/write to those devices from user space. Do I have to  instantiate devices and assign addresses to it in startup script?</p>
  
  <p>Thanks,
  Hemant </p>