Skip to content

Commit 8d49b2c

Browse files
committed
soundwire: get mipi-sdw-bra-mode-max-data-per-frame property
Get the mipi-sdw-bra-mode-max-data-per-frame property which indicates the maximum data payload size (in bytes per frame excluding header, CRC, and footer) for the BRA Mode. Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
1 parent cf1cca1 commit 8d49b2c

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

drivers/soundwire/mipi_disco.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -474,6 +474,9 @@ int sdw_slave_read_prop(struct sdw_slave *slave)
474474
device_property_read_u32(dev, "mipi-sdw-bra-mode-block-alignment",
475475
&prop->bra_block_alignment);
476476

477+
device_property_read_u32(dev, "mipi-sdw-bra-mode-max-data-per-frame",
478+
&prop->bra_max_data_per_frame);
479+
477480
prop->commit_register_supported = mipi_device_property_read_bool(dev,
478481
"mipi-sdw-commit-register-supported");
479482

include/linux/soundwire/sdw.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,8 @@ struct sdw_dpn_prop {
366366
* @lane_maps: Lane mapping for the slave, only valid if lane_control_support is set
367367
* @bra_block_alignment: If non-zero the length of data in a BRA frame must be
368368
* a multiple of this number of bytes.
369+
* @bra_max_data_per_frame: If non-zero the maximum data payload size (in bytes per
370+
frame excluding header, CRC, and footer) for this BRA Mode
369371
* @clock_reg_supported: the Peripheral implements the clock base and scale
370372
* registers introduced with the SoundWire 1.2 specification. SDCA devices
371373
* do not need to set this boolean property as the registers are required.
@@ -397,6 +399,7 @@ struct sdw_slave_prop {
397399
u8 scp_int1_mask;
398400
u8 lane_maps[SDW_MAX_LANES];
399401
u32 bra_block_alignment;
402+
u32 bra_max_data_per_frame;
400403
bool clock_reg_supported;
401404
bool use_domain_irq;
402405
};

0 commit comments

Comments
 (0)