Commit bfa4b4e6 authored by Michael Straube's avatar Michael Straube Committed by Greg Kroah-Hartman
Browse files

staging: r8188eu: remove UsbBulkOutSize from struct hal_data_8188e



UsbBulkOutSize in struct hal_data_8188e is only used to set a local
variable in rtl8188eu_xmitframe_complete(). Set the local variable
directly and remove UsbBulkOutSize from the hal_data_8188e structure.

Signed-off-by: default avatarMichael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220206144407.8397-1-straube.linux@gmail.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 3b011b09
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -382,7 +382,7 @@ static u32 xmitframe_need_length(struct xmit_frame *pxmitframe)

s32 rtl8188eu_xmitframe_complete(struct adapter *adapt, struct xmit_priv *pxmitpriv, struct xmit_buf *pxmitbuf)
{
	struct hal_data_8188e *haldata = &adapt->haldata;
	struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(adapt);
	struct xmit_frame *pxmitframe = NULL;
	struct xmit_frame *pfirstframe = NULL;

@@ -396,13 +396,18 @@ s32 rtl8188eu_xmitframe_complete(struct adapter *adapt, struct xmit_priv *pxmitp
	u32 pbuf_tail;	/*  last pkt tail */
	u32 len;	/*  packet length, except TXDESC_SIZE and PKT_OFFSET */

	u32 bulksize = haldata->UsbBulkOutSize;
	u32 bulksize;
	u8 desc_cnt;
	u32 bulkptr;

	/*  dump frame variable */
	u32 ff_hwaddr;

	if (pdvobjpriv->ishighspeed)
		bulksize = USB_HIGH_SPEED_BULK_SIZE;
	else
		bulksize = USB_FULL_SPEED_BULK_SIZE;

	/*  check xmitbuffer is ok */
	if (!pxmitbuf) {
		pxmitbuf = rtw_alloc_xmitbuf(pxmitpriv);
+1 −7
Original line number Diff line number Diff line
@@ -45,14 +45,8 @@ static bool HalUsbSetQueuePipeMapping8188EUsb(struct adapter *adapt, u8 NumOutPi

void rtl8188eu_interface_configure(struct adapter *adapt)
{
	struct hal_data_8188e *haldata = &adapt->haldata;
	struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(adapt);

	if (pdvobjpriv->ishighspeed)
		haldata->UsbBulkOutSize = USB_HIGH_SPEED_BULK_SIZE;/* 512 bytes */
	else
		haldata->UsbBulkOutSize = USB_FULL_SPEED_BULK_SIZE;/* 64 bytes */

	HalUsbSetQueuePipeMapping8188EUsb(adapt, pdvobjpriv->RtNumOutPipes);
}

+0 −2
Original line number Diff line number Diff line
@@ -171,8 +171,6 @@ struct hal_data_8188e {
	/*  Auto FSM to Turn On, include clock, isolation, power control
	 *  for MAC only */
	u8	bMacPwrCtrlOn;

	u32	UsbBulkOutSize;
};

s32 InitLLTTable(struct adapter *padapter, u8 txpktbuf_bndy);