Blame SOURCES/CVE-2023-45871.patch

277db7
From f5204071e2323f1d695a4d19be727fd6ad5f154c Mon Sep 17 00:00:00 2001
277db7
From: Joe Lawrence <joe.lawrence@redhat.com>
277db7
Date: Wed, 17 Jan 2024 15:29:28 -0500
277db7
Subject: [KPATCH CVE-2023-45871] kpatch fixes for CVE-2023-45871
277db7
277db7
Kernels:
277db7
3.10.0-1160.95.1.el7
277db7
3.10.0-1160.99.1.el7
277db7
3.10.0-1160.102.1.el7
277db7
3.10.0-1160.105.1.el7
277db7
277db7
277db7
Kpatch-MR: https://gitlab.com/redhat/prdsc/rhel/src/kpatch/rhel-7/-/merge_requests/65
277db7
Changes since last build:
277db7
[x86_64]:
277db7
igb_main.o: changed function: igb_configure
277db7
l2cap_core.o: changed function: l2cap_chan_hold
277db7
l2cap_core.o: changed function: l2cap_conn_get
277db7
l2cap_core.o: changed function: l2cap_global_chan_by_psm
277db7
l2cap_core.o: changed function: l2cap_recv_frame
277db7
l2cap_core.o: new function: klp_l2cap_le_sig_cmd
277db7
sch_atm.o: changed function: atm_tc_peek
277db7
sch_atm.o: changed function: sch_atm_dequeue
277db7
sch_drr.o: changed function: drr_dequeue
277db7
sch_dsmark.o: changed function: dsmark_peek
277db7
sch_hfsc.o: changed function: hfsc_enqueue
277db7
sch_hfsc.o: changed function: qdisc_peek_len
277db7
sch_multiq.o: changed function: multiq_peek
277db7
sch_prio.o: changed function: prio_peek
277db7
sch_qfq.o: changed function: qfq_dequeue
277db7
sch_qfq.o: changed function: qfq_enqueue
277db7
sch_red.o: changed function: red_peek
277db7
sch_sfb.o: changed function: sfb_peek
277db7
sch_tbf.o: changed function: tbf_dequeue
277db7
277db7
[ppc64le]:
277db7
l2cap_core.o: changed function: __l2cap_chan_add
277db7
l2cap_core.o: changed function: __l2cap_physical_cfm
277db7
l2cap_core.o: changed function: __set_monitor_timer
277db7
l2cap_core.o: changed function: __set_retrans_timer.part.24
277db7
l2cap_core.o: changed function: l2cap_ack_timeout
277db7
l2cap_core.o: changed function: l2cap_build_conf_req
277db7
l2cap_core.o: changed function: l2cap_chan_busy
277db7
l2cap_core.o: changed function: l2cap_chan_close
277db7
l2cap_core.o: changed function: l2cap_chan_connect
277db7
l2cap_core.o: changed function: l2cap_chan_del
277db7
l2cap_core.o: changed function: l2cap_chan_hold
277db7
l2cap_core.o: changed function: l2cap_chan_put
277db7
l2cap_core.o: changed function: l2cap_chan_send
277db7
l2cap_core.o: changed function: l2cap_chan_timeout
277db7
l2cap_core.o: changed function: l2cap_conn_add.part.28
277db7
l2cap_core.o: changed function: l2cap_conn_del
277db7
l2cap_core.o: changed function: l2cap_conn_start
277db7
l2cap_core.o: changed function: l2cap_connect
277db7
l2cap_core.o: changed function: l2cap_connect_cfm
277db7
l2cap_core.o: changed function: l2cap_connect_create_rsp
277db7
l2cap_core.o: changed function: l2cap_data_channel
277db7
l2cap_core.o: changed function: l2cap_disconn_cfm
277db7
l2cap_core.o: changed function: l2cap_do_create
277db7
l2cap_core.o: changed function: l2cap_do_start
277db7
l2cap_core.o: changed function: l2cap_ertm_resend
277db7
l2cap_core.o: changed function: l2cap_ertm_send
277db7
l2cap_core.o: changed function: l2cap_global_fixed_chan
277db7
l2cap_core.o: changed function: l2cap_handle_rej
277db7
l2cap_core.o: changed function: l2cap_handle_srej
277db7
l2cap_core.o: changed function: l2cap_logical_cfm
277db7
l2cap_core.o: changed function: l2cap_monitor_timeout
277db7
l2cap_core.o: changed function: l2cap_move_done
277db7
l2cap_core.o: changed function: l2cap_move_setup
277db7
l2cap_core.o: changed function: l2cap_parse_conf_rsp.constprop.36
277db7
l2cap_core.o: changed function: l2cap_pass_to_tx
277db7
l2cap_core.o: changed function: l2cap_process_reqseq
277db7
l2cap_core.o: changed function: l2cap_recv_frame
277db7
l2cap_core.o: changed function: l2cap_retrans_timeout
277db7
l2cap_core.o: changed function: l2cap_retransmit_all
277db7
l2cap_core.o: changed function: l2cap_rx
277db7
l2cap_core.o: changed function: l2cap_rx_state_recv
277db7
l2cap_core.o: changed function: l2cap_security_cfm
277db7
l2cap_core.o: changed function: l2cap_send_ack
277db7
l2cap_core.o: changed function: l2cap_send_efs_conf_rsp
277db7
l2cap_core.o: changed function: l2cap_send_i_or_rr_or_rnr
277db7
l2cap_core.o: changed function: l2cap_send_move_chan_cfm
277db7
l2cap_core.o: changed function: l2cap_send_move_chan_cfm_icid
277db7
l2cap_core.o: changed function: l2cap_send_move_chan_req
277db7
l2cap_core.o: changed function: l2cap_send_rr_or_rnr
277db7
l2cap_core.o: changed function: l2cap_send_sframe
277db7
l2cap_core.o: changed function: l2cap_send_srej
277db7
l2cap_core.o: changed function: l2cap_send_srej_tail
277db7
l2cap_core.o: changed function: l2cap_start_connection
277db7
l2cap_core.o: new function: l2cap_connect_req
277db7
sch_atm.o: changed function: atm_tc_bind_filter
277db7
sch_atm.o: changed function: atm_tc_change
277db7
sch_atm.o: changed function: atm_tc_delete
277db7
sch_atm.o: changed function: atm_tc_destroy
277db7
sch_atm.o: changed function: atm_tc_enqueue
277db7
sch_atm.o: changed function: atm_tc_find
277db7
sch_atm.o: changed function: atm_tc_graft
277db7
sch_atm.o: changed function: atm_tc_leaf
277db7
sch_atm.o: changed function: atm_tc_peek
277db7
sch_atm.o: changed function: atm_tc_put
277db7
sch_atm.o: changed function: atm_tc_reset
277db7
sch_atm.o: changed function: atm_tc_tcf_block
277db7
sch_atm.o: changed function: sch_atm_dequeue
277db7
sch_drr.o: changed function: drr_dequeue
277db7
sch_dsmark.o: changed function: dsmark_bind_filter
277db7
sch_dsmark.o: changed function: dsmark_change
277db7
sch_dsmark.o: changed function: dsmark_destroy
277db7
sch_dsmark.o: changed function: dsmark_dump_class
277db7
sch_dsmark.o: changed function: dsmark_init
277db7
sch_dsmark.o: changed function: dsmark_peek
277db7
sch_dsmark.o: changed function: dsmark_reset
277db7
sch_hfsc.o: changed function: hfsc_change_class
277db7
sch_hfsc.o: changed function: hfsc_dequeue
277db7
sch_hfsc.o: changed function: hfsc_enqueue
277db7
sch_multiq.o: changed function: multiq_peek
277db7
sch_prio.o: changed function: prio_peek
277db7
sch_qfq.o: changed function: qfq_dequeue
277db7
sch_qfq.o: changed function: qfq_enqueue
277db7
sch_red.o: changed function: red_peek
277db7
sch_sfb.o: changed function: sfb_peek
277db7
sch_tbf.o: changed function: tbf_dequeue
277db7
277db7
---------------------------
277db7
277db7
Modifications: none
277db7
277db7
commit de534cd6d39849339867a3d587c3c3b04776ef6e
277db7
Author: Wander Lairson Costa <wander@redhat.com>
277db7
Date:   Wed Jan 10 10:07:38 2024 -0300
277db7
277db7
    igb: set max size RX buffer when store bad packet is enabled
277db7
277db7
    JIRA: https://issues.redhat.com/browse/RHEL-15181
277db7
    CVE: CVE-2023-45871
277db7
277db7
    commit bb5ed01cd2428cd25b1c88a3a9cba87055eb289f
277db7
    Author: Radoslaw Tyl <radoslawx.tyl@intel.com>
277db7
    Date:   Thu Aug 24 13:46:19 2023 -0700
277db7
277db7
        igb: set max size RX buffer when store bad packet is enabled
277db7
277db7
        Increase the RX buffer size to 3K when the SBP bit is on. The size of
277db7
        the RX buffer determines the number of pages allocated which may not
277db7
        be sufficient for receive frames larger than the set MTU size.
277db7
277db7
        Cc: stable@vger.kernel.org
277db7
        Fixes: 89eaefb61dc9 ("igb: Support RX-ALL feature flag.")
277db7
        Reported-by: Manfred Rudigier <manfred.rudigier@omicronenergy.com>
277db7
        Signed-off-by: Radoslaw Tyl <radoslawx.tyl@intel.com>
277db7
        Tested-by: Arpana Arland <arpanax.arland@intel.com> (A Contingent worker at Intel)
277db7
        Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
277db7
        Signed-off-by: David S. Miller <davem@davemloft.net>
277db7
277db7
    Signed-off-by: Wander Lairson Costa <wander@redhat.com>
277db7
277db7
Signed-off-by: Joe Lawrence <joe.lawrence@redhat.com>
277db7
---
277db7
 drivers/net/ethernet/intel/igb/igb_main.c | 11 +++++++----
277db7
 1 file changed, 7 insertions(+), 4 deletions(-)
277db7
277db7
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
277db7
index 58fa02b36285..44b23384123e 100644
277db7
--- a/drivers/net/ethernet/intel/igb/igb_main.c
277db7
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
277db7
@@ -4576,6 +4576,10 @@ void igb_configure_rx_ring(struct igb_adapter *adapter,
277db7
 static void igb_set_rx_buffer_len(struct igb_adapter *adapter,
277db7
 				  struct igb_ring *rx_ring)
277db7
 {
277db7
+#if (PAGE_SIZE < 8192)
277db7
+	struct e1000_hw *hw = &adapter->hw;
277db7
+#endif
277db7
+
277db7
 	/* set build_skb and buffer size flags */
277db7
 	clear_ring_build_skb_enabled(rx_ring);
277db7
 	clear_ring_uses_large_buffer(rx_ring);
277db7
@@ -4586,10 +4590,9 @@ static void igb_set_rx_buffer_len(struct igb_adapter *adapter,
277db7
 	set_ring_build_skb_enabled(rx_ring);
277db7
 
277db7
 #if (PAGE_SIZE < 8192)
277db7
-	if (adapter->max_frame_size <= IGB_MAX_FRAME_BUILD_SKB)
277db7
-		return;
277db7
-
277db7
-	set_ring_uses_large_buffer(rx_ring);
277db7
+	if (adapter->max_frame_size > IGB_MAX_FRAME_BUILD_SKB ||
277db7
+	    rd32(E1000_RCTL) & E1000_RCTL_SBP)
277db7
+		set_ring_uses_large_buffer(rx_ring);
277db7
 #endif
277db7
 }
277db7
 
277db7
-- 
277db7
2.44.0
277db7
277db7