Commit 8a05eb89 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab Committed by Jonathan Corbet
Browse files

docs: misc-devices/pci-endpoint-test.txt: convert to ReST

parent 3471b9f7
Loading
Loading
Loading
Loading
+12 −12
Original line number Diff line number Diff line
---------------------------------
.. SPDX-License-Identifier: GPL-2.0

=============================
AD525x Digital Potentiometers
---------------------------------
=============================

The ad525x_dpot driver exports a simple sysfs interface.  This allows you to
work with the immediate resistance settings as well as update the saved startup
@@ -8,9 +10,8 @@ settings. Access to the factory programmed tolerance is also provided, but
interpretation of this settings is required by the end application according to
the specific part in use.

---------
Files
---------
=====

Each dpot device will have a set of eeprom, rdac, and tolerance files.  How
many depends on the actual part you have, as will the range of allowed values.
@@ -24,23 +25,22 @@ and may vary greatly on a part-by-part basis. For exact interpretation of
this field, please consult the datasheet for your part.  This is presented
as a hex file for easier parsing.

-----------
Example
-----------
=======

Locate the device in your sysfs tree.  This is probably easiest by going into
the common i2c directory and locating the device by the i2c slave address.
the common i2c directory and locating the device by the i2c slave address::

	# ls /sys/bus/i2c/devices/
	0-0022  0-0027  0-002f

So assuming the device in question is on the first i2c bus and has the slave
address of 0x2f, we descend (unrelated sysfs entries have been trimmed).
address of 0x2f, we descend (unrelated sysfs entries have been trimmed)::

	# ls /sys/bus/i2c/devices/0-002f/
	eeprom0 rdac0 tolerance0

You can use simple reads/writes to access these files:
You can use simple reads/writes to access these files::

	# cd /sys/bus/i2c/devices/0-002f/

+1 −0
Original line number Diff line number Diff line
@@ -14,6 +14,7 @@ fit into other categories.
.. toctree::
   :maxdepth: 2

   ad525x_dpot
   eeprom
   ibmvmc
   ics932s401
+1 −1
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@ config AD525X_DPOT
	  AD5271, AD5272, AD5274
	  digital potentiometer chips.

	  See Documentation/misc-devices/ad525x_dpot.txt for the
	  See Documentation/misc-devices/ad525x_dpot.rst for the
	  userspace interface.

	  This driver can also be built as a module.  If so, the module
+1 −1
Original line number Diff line number Diff line
@@ -58,7 +58,7 @@
 * AD5272		1		1024		20, 50, 100 (50-TP)
 * AD5274		1		256		20, 50, 100 (50-TP)
 *
 * See Documentation/misc-devices/ad525x_dpot.txt for more info.
 * See Documentation/misc-devices/ad525x_dpot.rst for more info.
 *
 * derived from ad5258.c
 * Copyright (c) 2009 Cyber Switching, Inc.