aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/net_dropmonitor.py
diff options
context:
space:
mode:
authorNuno Sa <[email protected]>2021-02-18 12:40:37 +0100
committerJonathan Cameron <[email protected]>2021-03-11 20:47:12 +0000
commit39c024b51b5607e9d2fc6c04c2573e4a778c728d (patch)
tree224235e41668b520d5ffe5eb0642cbf5577ea0a7 /tools/perf/scripts/python/net_dropmonitor.py
parent0463e60f087069adf25a815cd88753946aca2565 (diff)
iio: adis16475: improve sync scale mode handling
With this patch, we don't force users to define the IMU scaled internal sampling rate once in the devicetree. Now it's dynamically calculated at runtime depending on the desired output rate given by users. Calculating the sync_scale dynamically gives us better chances of achieving a perfect/integer value for DEC_RATE (thus giving more flexibility). The math is: 1. lcm of the input clock and the desired output rate. 2. get the highest multiple of the previous result lower than the adis max rate. 3. The last result becomes the IMU sample rate. Use that to calculate SYNC_SCALE and DEC_RATE (to get the user output rate). Signed-off-by: Nuno Sa <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/net_dropmonitor.py')
0 files changed, 0 insertions, 0 deletions