\hypertarget{ixgbe__vf_8c_source}{}\doxysection{ixgbe\+\_\+vf.\+c}
\label{ixgbe__vf_8c_source}\index{dev/ixgbe/ixgbe\_vf.c@{dev/ixgbe/ixgbe\_vf.c}}
\mbox{\hyperlink{ixgbe__vf_8c}{Go to the documentation of this file.}}
\begin{DoxyCode}{0}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00001}00001 \textcolor{comment}{/******************************************************************************}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00002}00002 \textcolor{comment}{  SPDX-\/License-\/Identifier: BSD-\/3-\/Clause}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00003}00003 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00004}00004 \textcolor{comment}{  Copyright (c) 2001-\/2020, Intel Corporation}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00005}00005 \textcolor{comment}{  All rights reserved.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00006}00006 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00007}00007 \textcolor{comment}{  Redistribution and use in source and binary forms, with or without}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00008}00008 \textcolor{comment}{  modification, are permitted provided that the following conditions are met:}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00009}00009 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00010}00010 \textcolor{comment}{   1. Redistributions of source code must retain the above copyright notice,}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00011}00011 \textcolor{comment}{      this list of conditions and the following disclaimer.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00012}00012 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00013}00013 \textcolor{comment}{   2. Redistributions in binary form must reproduce the above copyright}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00014}00014 \textcolor{comment}{      notice, this list of conditions and the following disclaimer in the}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00015}00015 \textcolor{comment}{      documentation and/or other materials provided with the distribution.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00016}00016 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00017}00017 \textcolor{comment}{   3. Neither the name of the Intel Corporation nor the names of its}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00018}00018 \textcolor{comment}{      contributors may be used to endorse or promote products derived from}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00019}00019 \textcolor{comment}{      this software without specific prior written permission.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00020}00020 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00021}00021 \textcolor{comment}{  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "{}AS IS"{}}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00022}00022 \textcolor{comment}{  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00023}00023 \textcolor{comment}{  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00024}00024 \textcolor{comment}{  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00025}00025 \textcolor{comment}{  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00026}00026 \textcolor{comment}{  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00027}00027 \textcolor{comment}{  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00028}00028 \textcolor{comment}{  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00029}00029 \textcolor{comment}{  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00030}00030 \textcolor{comment}{  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00031}00031 \textcolor{comment}{  POSSIBILITY OF SUCH DAMAGE.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00032}00032 \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00033}00033 \textcolor{comment}{******************************************************************************/}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00034}00034 \textcolor{comment}{/*\$FreeBSD\$*/}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00035}00035 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00036}00036 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00037}00037 \textcolor{preprocessor}{\#include "{}\mbox{\hyperlink{ixgbe_8h}{ixgbe.h}}"{}}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00038}00038 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00039}\mbox{\hyperlink{ixgbe__vf_8c_a30de82fb38b111f5c0ac56a4dc05765b}{00039}} \textcolor{preprocessor}{\#define IXGBE\_VFWRITE\_REG IXGBE\_WRITE\_REG}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00040}\mbox{\hyperlink{ixgbe__vf_8c_a323f383567afe0ed67336abf4cebe732}{00040}} \textcolor{preprocessor}{\#define IXGBE\_VFREAD\_REG IXGBE\_READ\_REG}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00041}00041 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00051}\mbox{\hyperlink{ixgbe__api_8h_af001c1570e5037ecb74c5dd8bef25a26}{00051}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_af001c1570e5037ecb74c5dd8bef25a26}{ixgbe\_init\_ops\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00052}00052 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00053}00053         \textcolor{comment}{/* MAC */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00054}00054         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a10201b332a746794f7fddc1648893944}{init\_hw}} = \mbox{\hyperlink{ixgbe__vf_8c_adf92699273772f28b5fef79f0d481550}{ixgbe\_init\_hw\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00055}00055         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a08f4138f91adedea9197cfc83c6a8e3e}{reset\_hw}} = \mbox{\hyperlink{ixgbe__vf_8c_ae9a30651a5b58209acbe172b9ac73b5d}{ixgbe\_reset\_hw\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00056}00056         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_adcfb6fc23421d1d304a4af9781a0488c}{start\_hw}} = \mbox{\hyperlink{ixgbe__vf_8c_a98656cde18b37a576116b64762364baa}{ixgbe\_start\_hw\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00057}00057         \textcolor{comment}{/* Cannot clear stats on VF */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00058}00058         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_ac3755f8e33e9e6424cec4e04eee9edc3}{clear\_hw\_cntrs}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00059}00059         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_ad531a7e5771c5b7ada36889c2b1bc876}{get\_media\_type}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00060}00060         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a2f1208f4d3e847e2ae7fac6d8458d0f7}{get\_mac\_addr}} = \mbox{\hyperlink{ixgbe__vf_8c_ac75609dff860c8d805d4959a101d8fb0}{ixgbe\_get\_mac\_addr\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00061}00061         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_ae5e0b22a150fdbefdad8de0032bef0f9}{stop\_adapter}} = \mbox{\hyperlink{ixgbe__vf_8c_ac1762d8525dd70bc25e7af4599e4bf69}{ixgbe\_stop\_adapter\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00062}00062         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_ad8e4b53625370c3ca7829901b1fda608}{get\_bus\_info}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00063}00063         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_af74f361a35fec7ea1d6b61d3de288c5d}{negotiate\_api\_version}} = \mbox{\hyperlink{ixgbe__vf_8c_a2acd56925bcbfa034a2f9e3757c00ed9}{ixgbevf\_negotiate\_api\_version}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00064}00064 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00065}00065         \textcolor{comment}{/* Link */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00066}00066         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a36e60def26d4ac7a2343a59df2a5eee7}{setup\_link}} = \mbox{\hyperlink{ixgbe__vf_8c_ae56aa90dae6458ca76c3eb4cd115ec69}{ixgbe\_setup\_mac\_link\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00067}00067         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a6944ef275d55e72031f26b6e79a480a3}{check\_link}} = \mbox{\hyperlink{ixgbe__vf_8c_aedf0fec2b72afe2abf559e2c5f3fdf2a}{ixgbe\_check\_mac\_link\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00068}00068         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_ab9e6d7c944e5acfdc2cd60384900c667}{get\_link\_capabilities}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00069}00069 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00070}00070         \textcolor{comment}{/* RAR, Multicast, VLAN */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00071}00071         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a45d31b154b2a6acfa89db115bded57ab}{set\_rar}} = \mbox{\hyperlink{ixgbe__vf_8c_ad99e8fe7db2e482b81ba44a5192d0987}{ixgbe\_set\_rar\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00072}00072         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a9d4ac70fd1d58e0809368f0c4ff20237}{set\_uc\_addr}} = \mbox{\hyperlink{ixgbe__vf_8c_ae6c090cd939c40913656cbab81c2b0c5}{ixgbevf\_set\_uc\_addr\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00073}00073         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a30784ff92466b4937a1cf4acebaa3dd6}{init\_rx\_addrs}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00074}00074         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a8e96276eb109d260291378be00978624}{update\_mc\_addr\_list}} = \mbox{\hyperlink{ixgbe__vf_8c_a5d90f3bd6b7114cafa75344ddae27876}{ixgbe\_update\_mc\_addr\_list\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00075}00075         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a129b2908b6021ceda14aa4a72bcfff8f}{update\_xcast\_mode}} = \mbox{\hyperlink{ixgbe__vf_8c_abee2d56665ac72c3d24c165f0097a437}{ixgbevf\_update\_xcast\_mode}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00076}00076         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a840b2a7bf74c35468631e5c1d07d3732}{get\_link\_state}} = \mbox{\hyperlink{ixgbe__vf_8c_a1774faaf76ec4054543a613f8a6d0547}{ixgbe\_get\_link\_state\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00077}00077         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a506ac8f38944f60becbc023d2f44a3df}{enable\_mc}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00078}00078         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a47679c987ae487e65fd2ed71d1d750e1}{disable\_mc}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00079}00079         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a54d464bfc1e322275aa7461601584745}{clear\_vfta}} = NULL;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00080}00080         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a8128cbca174c5bf7b8c296954da9248f}{set\_vfta}} = \mbox{\hyperlink{ixgbe__vf_8c_ab655a49ffe9562ccde20c8245cde3f85}{ixgbe\_set\_vfta\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00081}00081         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a2f3c5e49b74f9a54013590873439ff7e}{set\_rlpml}} = \mbox{\hyperlink{ixgbe__vf_8c_a79597f3bcdd1d2764662f913888af161}{ixgbevf\_rlpml\_set\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00082}00082 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00083}00083         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}} = 1;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00084}00084         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}} = 1;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00085}00085 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00086}00086         hw-\/>\mbox{\hyperlink{structixgbe__hw_a7740bbb42ff9d1a8c475e06df1fcc20e}{mbx}}.\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a85bb9d416b52d32649d865700c04baad}{init\_params}} = \mbox{\hyperlink{ixgbe__mbx_8c_a7bff2924b9c6a18ae6beb719ccc0cb3c}{ixgbe\_init\_mbx\_params\_vf}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00087}00087 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00088}00088         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00089}00089 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00090}00090 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00091}00091 \textcolor{comment}{/* ixgbe\_virt\_clr\_reg -\/ Set register to default (power on) state.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00092}00092 \textcolor{comment}{ * @hw: pointer to hardware structure}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00093}00093 \textcolor{comment}{ */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00094}\mbox{\hyperlink{ixgbe__vf_8c_a3e653adc4042efe99c5877ea1f260292}{00094}} \textcolor{keyword}{static} \textcolor{keywordtype}{void} \mbox{\hyperlink{ixgbe__vf_8c_a3e653adc4042efe99c5877ea1f260292}{ixgbe\_virt\_clr\_reg}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00095}00095 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00096}00096         \textcolor{keywordtype}{int} i;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00097}00097         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vfsrrctl;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00098}00098         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vfdca\_rxctrl;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00099}00099         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vfdca\_txctrl;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00100}00100 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00101}00101         \textcolor{comment}{/* VRSRRCTL default values (BSIZEPACKET = 2048, BSIZEHEADER = 256) */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00102}00102         vfsrrctl = 0x100 << \mbox{\hyperlink{ixgbe__type_8h_abcf518b45c0ddc2a54ea223f15d744e9}{IXGBE\_SRRCTL\_BSIZEHDRSIZE\_SHIFT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00103}00103         vfsrrctl |= 0x800 >> \mbox{\hyperlink{ixgbe__type_8h_ac29229a439c4159bfa3afc5d7621b3d7}{IXGBE\_SRRCTL\_BSIZEPKT\_SHIFT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00104}00104 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00105}00105         \textcolor{comment}{/* DCA\_RXCTRL default value */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00106}00106         vfdca\_rxctrl = \mbox{\hyperlink{ixgbe__type_8h_a5b2344de3d91088773de5ab7094f36c2}{IXGBE\_DCA\_RXCTRL\_DESC\_RRO\_EN}} |}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00107}00107                        \mbox{\hyperlink{ixgbe__type_8h_ad392e478370de1fa8a60186d7cafecfc}{IXGBE\_DCA\_RXCTRL\_DATA\_WRO\_EN}} |}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00108}00108                        \mbox{\hyperlink{ixgbe__type_8h_a435ccccfe00167c5de75d6224090c378}{IXGBE\_DCA\_RXCTRL\_HEAD\_WRO\_EN}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00109}00109 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00110}00110         \textcolor{comment}{/* DCA\_TXCTRL default value */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00111}00111         vfdca\_txctrl = \mbox{\hyperlink{ixgbe__type_8h_ab52ae3941ea9c9bd89aa54aa6e9f8fc3}{IXGBE\_DCA\_TXCTRL\_DESC\_RRO\_EN}} |}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00112}00112                        \mbox{\hyperlink{ixgbe__type_8h_abf90fae3185904de8af6ebad9de03af6}{IXGBE\_DCA\_TXCTRL\_DESC\_WRO\_EN}} |}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00113}00113                        \mbox{\hyperlink{ixgbe__type_8h_a12515fbd5c15621c490eb152862d1a55}{IXGBE\_DCA\_TXCTRL\_DATA\_RRO\_EN}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00114}00114 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00115}00115         \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_afc229d9562bd41cbaf7cb38a3b55d4f4}{IXGBE\_VFPSRTYPE}}, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00116}00116 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00117}00117         \textcolor{keywordflow}{for} (i = 0; i < 8; i++) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00118}00118                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_af5b3a952915f83e0c115b11c77ee9665}{IXGBE\_VFRDH}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00119}00119                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a772c6dbe18137c25ad5d75121b61c0f2}{IXGBE\_VFRDT}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00120}00120                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a92c040cea36fd018b96d989d5b32eb57}{IXGBE\_VFRXDCTL}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00121}00121                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a4803f6ccb62eb81d6862dbf02f705eed}{IXGBE\_VFSRRCTL}}(i), vfsrrctl);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00122}00122                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a6925e20c0f32e1bf14b7ab4dbb877dc7}{IXGBE\_VFTDH}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00123}00123                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_aceef0fc76351b8bc37f0e65eeafe04b1}{IXGBE\_VFTDT}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00124}00124                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a0139e1cf81cd1eed19cf349740dc40f2}{IXGBE\_VFTXDCTL}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00125}00125                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a1cab0cce7316d0edfbeb08485ad14f36}{IXGBE\_VFTDWBAH}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00126}00126                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a52071ff7ad3acc1da7663b42233de235}{IXGBE\_VFTDWBAL}}(i), 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00127}00127                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a967933789c1f6c24278268b8e5648bf6}{IXGBE\_VFDCA\_RXCTRL}}(i), vfdca\_rxctrl);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00128}00128                 \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a53bebf856c28cdee39ac4913d8eabe34}{IXGBE\_VFDCA\_TXCTRL}}(i), vfdca\_txctrl);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00129}00129         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00130}00130 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00131}00131         \mbox{\hyperlink{ixgbe__osdep_8h_aba51d1af185179ae07c68d874b12e06f}{IXGBE\_WRITE\_FLUSH}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00132}00132 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00133}00133 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00143}\mbox{\hyperlink{ixgbe__vf_8c_a98656cde18b37a576116b64762364baa}{00143}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_a98656cde18b37a576116b64762364baa}{ixgbe\_start\_hw\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00144}00144 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00145}00145         \textcolor{comment}{/* Clear adapter stopped flag */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00146}00146         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2182a35a3d4d23339ad65dfae72ffe8a}{adapter\_stopped}} = \textcolor{keyword}{false};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00147}00147 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00148}00148         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00149}00149 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00150}00150 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00158}\mbox{\hyperlink{ixgbe__vf_8c_adf92699273772f28b5fef79f0d481550}{00158}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_adf92699273772f28b5fef79f0d481550}{ixgbe\_init\_hw\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00159}00159 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00160}00160         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} status = hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_adcfb6fc23421d1d304a4af9781a0488c}{start\_hw}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00161}00161 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00162}00162         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_a2f1208f4d3e847e2ae7fac6d8458d0f7}{get\_mac\_addr}}(hw, hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_ad9b1279090d159ef15988435abd4a414}{addr}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00163}00163 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00164}00164         \textcolor{keywordflow}{return} status;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00165}00165 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00166}00166 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00174}\mbox{\hyperlink{ixgbe__vf_8c_ae9a30651a5b58209acbe172b9ac73b5d}{00174}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ae9a30651a5b58209acbe172b9ac73b5d}{ixgbe\_reset\_hw\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00175}00175 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00176}00176         \textcolor{keyword}{struct }\mbox{\hyperlink{structixgbe__mbx__info}{ixgbe\_mbx\_info}} *mbx = \&hw-\/>\mbox{\hyperlink{structixgbe__hw_a7740bbb42ff9d1a8c475e06df1fcc20e}{mbx}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00177}00177         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} \mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}} = \mbox{\hyperlink{ixgbe__type_8h_a530fad92d729ecee39739cb27f3e98c6}{IXGBE\_VF\_INIT\_TIMEOUT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00178}00178         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} ret\_val = \mbox{\hyperlink{ixgbe__type_8h_a0de9d3c111f5bb10f0d75dfdc9494897}{IXGBE\_ERR\_INVALID\_MAC\_ADDR}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00179}00179         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[\mbox{\hyperlink{ixgbe__mbx_8h_aacbdeca9689cf85f9221599122823196}{IXGBE\_VF\_PERMADDR\_MSG\_LEN}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00180}00180         \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *addr = (\mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *)(\&msgbuf[1]);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00181}00181 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00182}00182         \mbox{\hyperlink{ixgbe__osdep_8h_aa7aa4601bde10555b6aa50cd14dba16d}{DEBUGFUNC}}(\textcolor{stringliteral}{"{}ixgbevf\_reset\_hw\_vf"{}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00183}00183 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00184}00184         \textcolor{comment}{/* Call adapter stop to disable tx/rx and clear interrupts */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00185}00185         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aeda5aaacbeda485d61d8e1601efa0404}{ops}}.\mbox{\hyperlink{structixgbe__mac__operations_ae5e0b22a150fdbefdad8de0032bef0f9}{stop\_adapter}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00186}00186 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00187}00187         \textcolor{comment}{/* reset the api version */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00188}00188         hw-\/>\mbox{\hyperlink{structixgbe__hw_ab3335e18219ea21b8d35c85827d84fad}{api\_version}} = \mbox{\hyperlink{ixgbe__mbx_8h_ab1e5ca32b4afa2311aa69df7f103941aad70996bfd6c144bd8a1745a665301686}{ixgbe\_mbox\_api\_10}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00189}00189 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00190}00190         \mbox{\hyperlink{ixgbe__osdep_8h_a3732dd7571f0d578b722df9d5a6e8c9a}{DEBUGOUT}}(\textcolor{stringliteral}{"{}Issuing a function level reset to MAC\(\backslash\)n"{}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00191}00191 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00192}00192         \mbox{\hyperlink{ixgbe__vf_8c_a30de82fb38b111f5c0ac56a4dc05765b}{IXGBE\_VFWRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a1e2328531dcd683d17335f13a308d21d}{IXGBE\_VFCTRL}}, \mbox{\hyperlink{ixgbe__type_8h_af4182ca9351bd370459de94fb7147aec}{IXGBE\_CTRL\_RST}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00193}00193         \mbox{\hyperlink{ixgbe__osdep_8h_aba51d1af185179ae07c68d874b12e06f}{IXGBE\_WRITE\_FLUSH}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00194}00194 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00195}00195         \mbox{\hyperlink{ixgbe__osdep_8h_a112d66cf3347afa4dcb69db64604682f}{msec\_delay}}(50);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00196}00196 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00197}00197         \textcolor{comment}{/* we cannot reset while the RSTI / RSTD bits are asserted */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00198}00198         \textcolor{keywordflow}{while} (!mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a9777fcaab944e3f170ee6276e6614560}{check\_for\_rst}}(hw, 0) \&\& \mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00199}00199                 \mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}}-\/-\/;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00200}00200                 \mbox{\hyperlink{ixgbe__osdep_8h_a43e7beeb12e2b50153ba0f215b68bb85}{usec\_delay}}(5);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00201}00201         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00202}00202 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00203}00203         \textcolor{keywordflow}{if} (!\mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00204}00204                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_afabf79a3c419eba37818f598458b0979}{IXGBE\_ERR\_RESET\_FAILED}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00205}00205 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00206}00206         \textcolor{comment}{/* Reset VF registers to initial values */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00207}00207         \mbox{\hyperlink{ixgbe__vf_8c_a3e653adc4042efe99c5877ea1f260292}{ixgbe\_virt\_clr\_reg}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00208}00208 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00209}00209         \textcolor{comment}{/* mailbox timeout can now become active */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00210}00210         mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}} = \mbox{\hyperlink{ixgbe__mbx_8h_a73de2c7b01673682b0e6096ae0466b12}{IXGBE\_VF\_MBX\_INIT\_TIMEOUT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00211}00211 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00212}00212         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_a1247384ec4782746d80a5e4f81b7e58d}{IXGBE\_VF\_RESET}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00213}00213         mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a5a2bc9daa66820fcba64fe556e4cf2c6}{write\_posted}}(hw, msgbuf, 1, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00214}00214 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00215}00215         \mbox{\hyperlink{ixgbe__osdep_8h_a112d66cf3347afa4dcb69db64604682f}{msec\_delay}}(10);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00216}00216 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00217}00217         \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00218}00218 \textcolor{comment}{         * set our "{}perm\_addr"{} based on info provided by PF}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00219}00219 \textcolor{comment}{         * also set up the mc\_filter\_type which is piggy backed}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00220}00220 \textcolor{comment}{         * on the mac address in word 3}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00221}00221 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00222}00222         ret\_val = mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a12f4181742e0d2e52cf3c324a5387de1}{read\_posted}}(hw, msgbuf,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00223}00223                         \mbox{\hyperlink{ixgbe__mbx_8h_aacbdeca9689cf85f9221599122823196}{IXGBE\_VF\_PERMADDR\_MSG\_LEN}}, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00224}00224         \textcolor{keywordflow}{if} (ret\_val)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00225}00225                 \textcolor{keywordflow}{return} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00226}00226 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00227}00227         \textcolor{keywordflow}{if} (msgbuf[0] != (\mbox{\hyperlink{ixgbe__mbx_8h_a1247384ec4782746d80a5e4f81b7e58d}{IXGBE\_VF\_RESET}} | \mbox{\hyperlink{ixgbe__mbx_8h_a034f76a9383ab6053fafe5b84b97efea}{IXGBE\_VT\_MSGTYPE\_ACK}}) \&\&}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00228}00228             msgbuf[0] != (\mbox{\hyperlink{ixgbe__mbx_8h_a1247384ec4782746d80a5e4f81b7e58d}{IXGBE\_VF\_RESET}} | \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00229}00229                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a0de9d3c111f5bb10f0d75dfdc9494897}{IXGBE\_ERR\_INVALID\_MAC\_ADDR}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00230}00230 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00231}00231         \textcolor{keywordflow}{if} (msgbuf[0] == (\mbox{\hyperlink{ixgbe__mbx_8h_a1247384ec4782746d80a5e4f81b7e58d}{IXGBE\_VF\_RESET}} | \mbox{\hyperlink{ixgbe__mbx_8h_a034f76a9383ab6053fafe5b84b97efea}{IXGBE\_VT\_MSGTYPE\_ACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00232}00232                 memcpy(hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a3ae6e60130d30d544db7025eeb93543e}{perm\_addr}}, addr, \mbox{\hyperlink{ixgbe__type_8h_a1438184ce1c283a07cdee917d9fa1b6c}{IXGBE\_ETH\_LENGTH\_OF\_ADDRESS}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00233}00233 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00234}00234         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aaee3293da426ec23e94343e2064f380f}{mc\_filter\_type}} = msgbuf[\mbox{\hyperlink{ixgbe__mbx_8h_a08c0a2b05ac2f14b14a78570bb7daf5b}{IXGBE\_VF\_MC\_TYPE\_WORD}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00235}00235 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00236}00236         \textcolor{keywordflow}{return} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00237}00237 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00238}00238 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00248}\mbox{\hyperlink{ixgbe__vf_8c_ac1762d8525dd70bc25e7af4599e4bf69}{00248}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ac1762d8525dd70bc25e7af4599e4bf69}{ixgbe\_stop\_adapter\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00249}00249 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00250}00250         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} reg\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00251}00251         \mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}} i;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00252}00252 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00253}00253         \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00254}00254 \textcolor{comment}{         * Set the adapter\_stopped flag so other driver functions stop touching}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00255}00255 \textcolor{comment}{         * the hardware}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00256}00256 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00257}00257         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2182a35a3d4d23339ad65dfae72ffe8a}{adapter\_stopped}} = \textcolor{keyword}{true};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00258}00258 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00259}00259         \textcolor{comment}{/* Clear interrupt mask to stop from interrupts being generated */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00260}00260         \mbox{\hyperlink{ixgbe__vf_8c_a30de82fb38b111f5c0ac56a4dc05765b}{IXGBE\_VFWRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a0e435be89355d31e2d7b2eb0a55fcfd2}{IXGBE\_VTEIMC}}, \mbox{\hyperlink{ixgbe__vf_8h_a23d80cd162eeae8eebd99d2bfee08971}{IXGBE\_VF\_IRQ\_CLEAR\_MASK}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00261}00261 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00262}00262         \textcolor{comment}{/* Clear any pending interrupts, flush previous writes */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00263}00263         \mbox{\hyperlink{ixgbe__vf_8c_a323f383567afe0ed67336abf4cebe732}{IXGBE\_VFREAD\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a22444951d6a9636c0830856f099c4977}{IXGBE\_VTEICR}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00264}00264 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00265}00265         \textcolor{comment}{/* Disable the transmit unit.  Each queue must be disabled. */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00266}00266         \textcolor{keywordflow}{for} (i = 0; i < hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}}; i++)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00267}00267                 \mbox{\hyperlink{ixgbe__vf_8c_a30de82fb38b111f5c0ac56a4dc05765b}{IXGBE\_VFWRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a0139e1cf81cd1eed19cf349740dc40f2}{IXGBE\_VFTXDCTL}}(i), \mbox{\hyperlink{ixgbe__type_8h_a362652160311a4b75cfcdc49227c949d}{IXGBE\_TXDCTL\_SWFLSH}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00268}00268 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00269}00269         \textcolor{comment}{/* Disable the receive unit by stopping each queue */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00270}00270         \textcolor{keywordflow}{for} (i = 0; i < hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}}; i++) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00271}00271                 reg\_val = \mbox{\hyperlink{ixgbe__vf_8c_a323f383567afe0ed67336abf4cebe732}{IXGBE\_VFREAD\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a92c040cea36fd018b96d989d5b32eb57}{IXGBE\_VFRXDCTL}}(i));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00272}00272                 reg\_val \&= \string~IXGBE\_RXDCTL\_ENABLE;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00273}00273                 \mbox{\hyperlink{ixgbe__vf_8c_a30de82fb38b111f5c0ac56a4dc05765b}{IXGBE\_VFWRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_a92c040cea36fd018b96d989d5b32eb57}{IXGBE\_VFRXDCTL}}(i), reg\_val);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00274}00274         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00275}00275         \textcolor{comment}{/* Clear packet split and pool config */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00276}00276         \mbox{\hyperlink{ixgbe__osdep_8h_ac285f4dea03f431a8f2718d56f88ea6f}{IXGBE\_WRITE\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_afc229d9562bd41cbaf7cb38a3b55d4f4}{IXGBE\_VFPSRTYPE}}, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00277}00277 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00278}00278         \textcolor{comment}{/* flush all queues disables */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00279}00279         \mbox{\hyperlink{ixgbe__osdep_8h_aba51d1af185179ae07c68d874b12e06f}{IXGBE\_WRITE\_FLUSH}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00280}00280         \mbox{\hyperlink{ixgbe__osdep_8h_a112d66cf3347afa4dcb69db64604682f}{msec\_delay}}(2);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00281}00281 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00282}00282         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00283}00283 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00284}00284 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00297}\mbox{\hyperlink{ixgbe__vf_8c_a06b7b0a70d9af5e2fa8120b11d970228}{00297}} \textcolor{keyword}{static} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_a06b7b0a70d9af5e2fa8120b11d970228}{ixgbe\_mta\_vector}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *mc\_addr)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00298}00298 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00299}00299         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vector = 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00300}00300 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00301}00301         \textcolor{keywordflow}{switch} (hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aaee3293da426ec23e94343e2064f380f}{mc\_filter\_type}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00302}00302         \textcolor{keywordflow}{case} 0:   \textcolor{comment}{/* use bits [47:36] of the address */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00303}00303                 vector = ((mc\_addr[4] >> 4) | (((\mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}})mc\_addr[5]) << 4));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00304}00304                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00305}00305         \textcolor{keywordflow}{case} 1:   \textcolor{comment}{/* use bits [46:35] of the address */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00306}00306                 vector = ((mc\_addr[4] >> 3) | (((\mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}})mc\_addr[5]) << 5));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00307}00307                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00308}00308         \textcolor{keywordflow}{case} 2:   \textcolor{comment}{/* use bits [45:34] of the address */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00309}00309                 vector = ((mc\_addr[4] >> 2) | (((\mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}})mc\_addr[5]) << 6));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00310}00310                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00311}00311         \textcolor{keywordflow}{case} 3:   \textcolor{comment}{/* use bits [43:32] of the address */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00312}00312                 vector = ((mc\_addr[4]) | (((\mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}})mc\_addr[5]) << 8));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00313}00313                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00314}00314         \textcolor{keywordflow}{default}:  \textcolor{comment}{/* Invalid mc\_filter\_type */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00315}00315                 \mbox{\hyperlink{ixgbe__osdep_8h_a3732dd7571f0d578b722df9d5a6e8c9a}{DEBUGOUT}}(\textcolor{stringliteral}{"{}MC filter type param set incorrectly\(\backslash\)n"{}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00316}00316                 \mbox{\hyperlink{ixgbe__osdep_8h_aca68c0d4ac8df0838e209fb5300f7be3}{ASSERT}}(0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00317}00317                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00318}00318         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00319}00319 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00320}00320         \textcolor{comment}{/* vector can only be 12-\/bits or boundary will be exceeded */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00321}00321         vector \&= 0xFFF;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00322}00322         \textcolor{keywordflow}{return} vector;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00323}00323 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00324}00324 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00325}\mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{00325}} \textcolor{keyword}{static} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} *msg,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00326}00326                                       \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} *retmsg, \mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}} \mbox{\hyperlink{structixgbe__mbx__info_ae9f862d3feb224520e9a185cdd1a1134}{size}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00327}00327 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00328}00328         \textcolor{keyword}{struct }\mbox{\hyperlink{structixgbe__mbx__info}{ixgbe\_mbx\_info}} *mbx = \&hw-\/>\mbox{\hyperlink{structixgbe__hw_a7740bbb42ff9d1a8c475e06df1fcc20e}{mbx}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00329}00329         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} retval = mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a5a2bc9daa66820fcba64fe556e4cf2c6}{write\_posted}}(hw, msg, \mbox{\hyperlink{structixgbe__mbx__info_ae9f862d3feb224520e9a185cdd1a1134}{size}}, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00330}00330 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00331}00331         \textcolor{keywordflow}{if} (retval)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00332}00332                 \textcolor{keywordflow}{return} retval;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00333}00333 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00334}00334         \textcolor{keywordflow}{return} mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a12f4181742e0d2e52cf3c324a5387de1}{read\_posted}}(hw, retmsg, \mbox{\hyperlink{structixgbe__mbx__info_ae9f862d3feb224520e9a185cdd1a1134}{size}}, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00335}00335 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00336}00336 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00345}\mbox{\hyperlink{ixgbe__vf_8c_ad99e8fe7db2e482b81ba44a5192d0987}{00345}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ad99e8fe7db2e482b81ba44a5192d0987}{ixgbe\_set\_rar\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} index, \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *addr, \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vmdq,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00346}00346                      \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} enable\_addr)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00347}00347 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00348}00348         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[3];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00349}00349         \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *msg\_addr = (\mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *)(\&msgbuf[1]);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00350}00350         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00351}00351         \mbox{\hyperlink{ixgbe__osdep_8h_aeaecf4f21ba0c098dc14e2ef61b86ee2}{UNREFERENCED\_3PARAMETER}}(vmdq, enable\_addr, index);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00352}00352 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00353}00353         memset(msgbuf, 0, 12);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00354}00354         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_ae61544f426e8e49112f2b25a9f1e252d}{IXGBE\_VF\_SET\_MAC\_ADDR}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00355}00355         memcpy(msg\_addr, addr, 6);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00356}00356         ret\_val = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msgbuf, msgbuf, 3);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00357}00357 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00358}00358         msgbuf[0] \&= \string~IXGBE\_VT\_MSGTYPE\_CTS;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00359}00359 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00360}00360         \textcolor{comment}{/* if nacked the address was rejected, use "{}perm\_addr"{} */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00361}00361         \textcolor{keywordflow}{if} (!ret\_val \&\&}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00362}00362             (msgbuf[0] == (\mbox{\hyperlink{ixgbe__mbx_8h_ae61544f426e8e49112f2b25a9f1e252d}{IXGBE\_VF\_SET\_MAC\_ADDR}} | \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}}))) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00363}00363                 \mbox{\hyperlink{ixgbe__vf_8c_ac75609dff860c8d805d4959a101d8fb0}{ixgbe\_get\_mac\_addr\_vf}}(hw, hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_ad9b1279090d159ef15988435abd4a414}{addr}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00364}00364                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__mbx_8h_ab7becba651f174dffad1f23cbde2ebf6}{IXGBE\_ERR\_MBX}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00365}00365         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00366}00366 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00367}00367         \textcolor{keywordflow}{return} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00368}00368 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00369}00369 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00380}\mbox{\hyperlink{ixgbe__vf_8c_a5d90f3bd6b7114cafa75344ddae27876}{00380}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_a5d90f3bd6b7114cafa75344ddae27876}{ixgbe\_update\_mc\_addr\_list\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *mc\_addr\_list,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00381}00381                                  \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} mc\_addr\_count, \mbox{\hyperlink{ixgbe__type_8h_a58504ac90fabd39534ed0d2f633cea9a}{ixgbe\_mc\_addr\_itr}} next,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00382}00382                                  \textcolor{keywordtype}{bool} clear)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00383}00383 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00384}00384         \textcolor{keyword}{struct }\mbox{\hyperlink{structixgbe__mbx__info}{ixgbe\_mbx\_info}} *mbx = \&hw-\/>\mbox{\hyperlink{structixgbe__hw_a7740bbb42ff9d1a8c475e06df1fcc20e}{mbx}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00385}00385         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[\mbox{\hyperlink{ixgbe__mbx_8h_a7429c7cc916f8d54e5a3ae8956e5f043}{IXGBE\_VFMAILBOX\_SIZE}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00386}00386         \mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}} *vector\_list = (\mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}} *)\&msgbuf[1];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00387}00387         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vector;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00388}00388         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} cnt, i;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00389}00389         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vmdq;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00390}00390 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00391}00391         \mbox{\hyperlink{ixgbe__osdep_8h_ab34c0571e37c4459b45372cd899a1c8c}{UNREFERENCED\_1PARAMETER}}(clear);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00392}00392 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00393}00393         \mbox{\hyperlink{ixgbe__osdep_8h_aa7aa4601bde10555b6aa50cd14dba16d}{DEBUGFUNC}}(\textcolor{stringliteral}{"{}ixgbe\_update\_mc\_addr\_list\_vf"{}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00394}00394 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00395}00395         \textcolor{comment}{/* Each entry in the list uses 1 16 bit word.  We have 30}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00396}00396 \textcolor{comment}{         * 16 bit words available in our HW msg buffer (minus 1 for the}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00397}00397 \textcolor{comment}{         * msg type).  That's 30 hash values if we pack 'em right.  If}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00398}00398 \textcolor{comment}{         * there are more than 30 MC addresses to add then punt the}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00399}00399 \textcolor{comment}{         * extras for now and then add code to handle more than 30 later.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00400}00400 \textcolor{comment}{         * It would be unusual for a server to request that many multi-\/cast}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00401}00401 \textcolor{comment}{         * addresses except for in large enterprise network environments.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00402}00402 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00403}00403 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00404}00404         \mbox{\hyperlink{ixgbe__osdep_8h_aaf85755fe175273a584a57ca1c6a6f93}{DEBUGOUT1}}(\textcolor{stringliteral}{"{}MC Addr Count = \%d\(\backslash\)n"{}}, mc\_addr\_count);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00405}00405 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00406}00406         cnt = (mc\_addr\_count > 30) ? 30 : mc\_addr\_count;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00407}00407         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_ae525b34ec6d4014fd168d18e4aba8c95}{IXGBE\_VF\_SET\_MULTICAST}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00408}00408         msgbuf[0] |= cnt << \mbox{\hyperlink{ixgbe__mbx_8h_a556645856ccb01321dd2adf27a7fc3b2}{IXGBE\_VT\_MSGINFO\_SHIFT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00409}00409 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00410}00410         \textcolor{keywordflow}{for} (i = 0; i < cnt; i++) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00411}00411                 vector = \mbox{\hyperlink{ixgbe__vf_8c_a06b7b0a70d9af5e2fa8120b11d970228}{ixgbe\_mta\_vector}}(hw, next(hw, \&mc\_addr\_list, \&vmdq));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00412}00412                 \mbox{\hyperlink{ixgbe__osdep_8h_aaf85755fe175273a584a57ca1c6a6f93}{DEBUGOUT1}}(\textcolor{stringliteral}{"{}Hash value = 0x\%03X\(\backslash\)n"{}}, vector);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00413}00413                 vector\_list[i] = (\mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}})vector;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00414}00414         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00415}00415 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00416}00416         \textcolor{keywordflow}{return} mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a5a2bc9daa66820fcba64fe556e4cf2c6}{write\_posted}}(hw, msgbuf, \mbox{\hyperlink{ixgbe__mbx_8h_a7429c7cc916f8d54e5a3ae8956e5f043}{IXGBE\_VFMAILBOX\_SIZE}}, 0);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00417}00417 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00418}00418 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00426}\mbox{\hyperlink{ixgbe__vf_8c_abee2d56665ac72c3d24c165f0097a437}{00426}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_abee2d56665ac72c3d24c165f0097a437}{ixgbevf\_update\_xcast\_mode}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \textcolor{keywordtype}{int} xcast\_mode)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00427}00427 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00428}00428         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[2];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00429}00429         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00430}00430 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00431}00431         \textcolor{keywordflow}{switch} (hw-\/>\mbox{\hyperlink{structixgbe__hw_ab3335e18219ea21b8d35c85827d84fad}{api\_version}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00432}00432         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__mbx_8h_ab1e5ca32b4afa2311aa69df7f103941aa2bee52cfe7c071f801eeab96deee57da}{ixgbe\_mbox\_api\_12}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00433}00433                 \textcolor{comment}{/* New modes were introduced in 1.3 version */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00434}00434                 \textcolor{keywordflow}{if} (xcast\_mode > \mbox{\hyperlink{ixgbe__mbx_8h_aa76d8a185d4a65488cb5386d0bd4349ba6021265325f672627eb52a1455517008}{IXGBEVF\_XCAST\_MODE\_ALLMULTI}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00435}00435                         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a69c3f56d7a3e04090aaa7d30a07eb22b}{IXGBE\_ERR\_FEATURE\_NOT\_SUPPORTED}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00436}00436                 \textcolor{comment}{/* Fall through */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00437}00437         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__mbx_8h_ab1e5ca32b4afa2311aa69df7f103941aae0b407460c7b172fb11b665954db7d6e}{ixgbe\_mbox\_api\_13}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00438}00438                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00439}00439         \textcolor{keywordflow}{default}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00440}00440                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a69c3f56d7a3e04090aaa7d30a07eb22b}{IXGBE\_ERR\_FEATURE\_NOT\_SUPPORTED}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00441}00441         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00442}00442 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00443}00443         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_adbd91b07cc81ab98b7141c60a8bb2cd0}{IXGBE\_VF\_UPDATE\_XCAST\_MODE}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00444}00444         msgbuf[1] = xcast\_mode;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00445}00445 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00446}00446         err = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msgbuf, msgbuf, 2);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00447}00447         \textcolor{keywordflow}{if} (err)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00448}00448                 \textcolor{keywordflow}{return} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00449}00449 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00450}00450         msgbuf[0] \&= \string~IXGBE\_VT\_MSGTYPE\_CTS;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00451}00451         \textcolor{keywordflow}{if} (msgbuf[0] == (\mbox{\hyperlink{ixgbe__mbx_8h_adbd91b07cc81ab98b7141c60a8bb2cd0}{IXGBE\_VF\_UPDATE\_XCAST\_MODE}} | \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00452}00452                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a69c3f56d7a3e04090aaa7d30a07eb22b}{IXGBE\_ERR\_FEATURE\_NOT\_SUPPORTED}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00453}00453         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00454}00454 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00455}00455 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00463}\mbox{\hyperlink{ixgbe__vf_8c_a1774faaf76ec4054543a613f8a6d0547}{00463}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_a1774faaf76ec4054543a613f8a6d0547}{ixgbe\_get\_link\_state\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \textcolor{keywordtype}{bool} *link\_state)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00464}00464 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00465}00465         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[2];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00466}00466         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00467}00467         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00468}00468 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00469}00469         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_a8355222864323d578983736759abd89a}{IXGBE\_VF\_GET\_LINK\_STATE}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00470}00470         msgbuf[1] = 0x0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00471}00471 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00472}00472         err = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msgbuf, msgbuf, 2);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00473}00473 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00474}00474         \textcolor{keywordflow}{if} (err || (msgbuf[0] \& \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}})) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00475}00475                 ret\_val = \mbox{\hyperlink{ixgbe__mbx_8h_ab7becba651f174dffad1f23cbde2ebf6}{IXGBE\_ERR\_MBX}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00476}00476         \} \textcolor{keywordflow}{else} \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00477}00477                 ret\_val = \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00478}00478                 *link\_state = msgbuf[1];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00479}00479         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00480}00480 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00481}00481         \textcolor{keywordflow}{return} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00482}00482 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00483}00483 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00494}\mbox{\hyperlink{ixgbe__vf_8c_ab655a49ffe9562ccde20c8245cde3f85}{00494}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ab655a49ffe9562ccde20c8245cde3f85}{ixgbe\_set\_vfta\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vlan, \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} vind,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00495}00495                       \textcolor{keywordtype}{bool} vlan\_on, \textcolor{keywordtype}{bool} vlvf\_bypass)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00496}00496 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00497}00497         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[2];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00498}00498         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00499}00499         \mbox{\hyperlink{ixgbe__osdep_8h_a04887b5b918df8cce29764f607fca679}{UNREFERENCED\_2PARAMETER}}(vind, vlvf\_bypass);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00500}00500 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00501}00501         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_a414ecb13b8e3aaccf27f166708508457}{IXGBE\_VF\_SET\_VLAN}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00502}00502         msgbuf[1] = vlan;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00503}00503         \textcolor{comment}{/* Setting the 8 bit field MSG INFO to true indicates "{}add"{} */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00504}00504         msgbuf[0] |= vlan\_on << \mbox{\hyperlink{ixgbe__mbx_8h_a556645856ccb01321dd2adf27a7fc3b2}{IXGBE\_VT\_MSGINFO\_SHIFT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00505}00505 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00506}00506         ret\_val = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msgbuf, msgbuf, 2);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00507}00507         \textcolor{keywordflow}{if} (!ret\_val \&\& (msgbuf[0] \& \mbox{\hyperlink{ixgbe__mbx_8h_a034f76a9383ab6053fafe5b84b97efea}{IXGBE\_VT\_MSGTYPE\_ACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00508}00508                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00509}00509 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00510}00510         \textcolor{keywordflow}{return} ret\_val | (msgbuf[0] \& \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00511}00511 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00512}00512 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00519}\mbox{\hyperlink{ixgbe__vf_8c_ae0cbc3f25f248108083d7dc312c21579}{00519}} \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} \mbox{\hyperlink{ixgbe__vf_8c_ae0cbc3f25f248108083d7dc312c21579}{ixgbe\_get\_num\_of\_tx\_queues\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00520}00520 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00521}00521         \mbox{\hyperlink{ixgbe__osdep_8h_ab34c0571e37c4459b45372cd899a1c8c}{UNREFERENCED\_1PARAMETER}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00522}00522         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__vf_8h_aacc0f62640daf1d0c55fb18c829f9442}{IXGBE\_VF\_MAX\_TX\_QUEUES}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00523}00523 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00524}00524 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00531}\mbox{\hyperlink{ixgbe__vf_8c_a6861e4dd74d79209a2386d0a4061dbb3}{00531}} \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} \mbox{\hyperlink{ixgbe__vf_8c_a6861e4dd74d79209a2386d0a4061dbb3}{ixgbe\_get\_num\_of\_rx\_queues\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00532}00532 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00533}00533         \mbox{\hyperlink{ixgbe__osdep_8h_ab34c0571e37c4459b45372cd899a1c8c}{UNREFERENCED\_1PARAMETER}}(hw);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00534}00534         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__vf_8h_a7f7fdb4b7cb245fe291337d647746edf}{IXGBE\_VF\_MAX\_RX\_QUEUES}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00535}00535 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00536}00536 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00542}\mbox{\hyperlink{ixgbe__vf_8c_ac75609dff860c8d805d4959a101d8fb0}{00542}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ac75609dff860c8d805d4959a101d8fb0}{ixgbe\_get\_mac\_addr\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *mac\_addr)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00543}00543 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00544}00544         \textcolor{keywordtype}{int} i;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00545}00545 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00546}00546         \textcolor{keywordflow}{for} (i = 0; i < \mbox{\hyperlink{ixgbe__type_8h_a1438184ce1c283a07cdee917d9fa1b6c}{IXGBE\_ETH\_LENGTH\_OF\_ADDRESS}}; i++)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00547}00547                 mac\_addr[i] = hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a3ae6e60130d30d544db7025eeb93543e}{perm\_addr}}[i];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00548}00548 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00549}00549         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00550}00550 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00551}00551 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00552}\mbox{\hyperlink{ixgbe__vf_8c_ae6c090cd939c40913656cbab81c2b0c5}{00552}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ae6c090cd939c40913656cbab81c2b0c5}{ixgbevf\_set\_uc\_addr\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} index, \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *addr)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00553}00553 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00554}00554         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[3], msgbuf\_chk;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00555}00555         \mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *msg\_addr = (\mbox{\hyperlink{ixgbe__osdep_8h_a92c50087ca0e64fa93fc59402c55f8ca}{u8}} *)(\&msgbuf[1]);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00556}00556         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00557}00557 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00558}00558         memset(msgbuf, 0, \textcolor{keyword}{sizeof}(msgbuf));}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00559}00559         \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00560}00560 \textcolor{comment}{         * If index is one then this is the start of a new list and needs}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00561}00561 \textcolor{comment}{         * indication to the PF so it can do it's own list management.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00562}00562 \textcolor{comment}{         * If it is zero then that tells the PF to just clear all of}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00563}00563 \textcolor{comment}{         * this VF's macvlans and there is no new list.}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00564}00564 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00565}00565         msgbuf[0] |= index << \mbox{\hyperlink{ixgbe__mbx_8h_a556645856ccb01321dd2adf27a7fc3b2}{IXGBE\_VT\_MSGINFO\_SHIFT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00566}00566         msgbuf[0] |= \mbox{\hyperlink{ixgbe__mbx_8h_a7c79503ac857840c283f1a5c38a5ab2d}{IXGBE\_VF\_SET\_MACVLAN}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00567}00567         msgbuf\_chk = msgbuf[0];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00568}00568         \textcolor{keywordflow}{if} (addr)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00569}00569                 memcpy(msg\_addr, addr, 6);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00570}00570 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00571}00571         ret\_val = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msgbuf, msgbuf, 3);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00572}00572         \textcolor{keywordflow}{if} (!ret\_val) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00573}00573                 msgbuf[0] \&= \string~IXGBE\_VT\_MSGTYPE\_CTS;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00574}00574 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00575}00575                 \textcolor{keywordflow}{if} (msgbuf[0] == (msgbuf\_chk | \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00576}00576                         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_ab87ddb1190c87d2156d4ac20ce03fab1}{IXGBE\_ERR\_OUT\_OF\_MEM}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00577}00577         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00578}00578 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00579}00579         \textcolor{keywordflow}{return} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00580}00580 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00581}00581 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00590}\mbox{\hyperlink{ixgbe__vf_8c_ae56aa90dae6458ca76c3eb4cd115ec69}{00590}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_ae56aa90dae6458ca76c3eb4cd115ec69}{ixgbe\_setup\_mac\_link\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__type_8h_a477413d4007751d6682c7b44bd272828}{ixgbe\_link\_speed}} speed,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00591}00591                             \textcolor{keywordtype}{bool} autoneg\_wait\_to\_complete)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00592}00592 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00593}00593         \mbox{\hyperlink{ixgbe__osdep_8h_aeaecf4f21ba0c098dc14e2ef61b86ee2}{UNREFERENCED\_3PARAMETER}}(hw, speed, autoneg\_wait\_to\_complete);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00594}00594         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00595}00595 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00596}00596 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00606}\mbox{\hyperlink{ixgbe__vf_8c_aedf0fec2b72afe2abf559e2c5f3fdf2a}{00606}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_aedf0fec2b72afe2abf559e2c5f3fdf2a}{ixgbe\_check\_mac\_link\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__type_8h_a477413d4007751d6682c7b44bd272828}{ixgbe\_link\_speed}} *speed,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00607}00607                             \textcolor{keywordtype}{bool} *link\_up, \textcolor{keywordtype}{bool} autoneg\_wait\_to\_complete)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00608}00608 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00609}00609         \textcolor{keyword}{struct }\mbox{\hyperlink{structixgbe__mbx__info}{ixgbe\_mbx\_info}} *mbx = \&hw-\/>\mbox{\hyperlink{structixgbe__hw_a7740bbb42ff9d1a8c475e06df1fcc20e}{mbx}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00610}00610         \textcolor{keyword}{struct }\mbox{\hyperlink{structixgbe__mac__info}{ixgbe\_mac\_info}} *mac = \&hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00611}00611         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} ret\_val = \mbox{\hyperlink{ixgbe__type_8h_a5434058a795f587d973e6f463d2ae8b8}{IXGBE\_SUCCESS}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00612}00612         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} links\_reg;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00613}00613         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} in\_msg = 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00614}00614         \mbox{\hyperlink{ixgbe__osdep_8h_ab34c0571e37c4459b45372cd899a1c8c}{UNREFERENCED\_1PARAMETER}}(autoneg\_wait\_to\_complete);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00615}00615 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00616}00616         \textcolor{comment}{/* If we were hit with a reset drop the link */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00617}00617         \textcolor{keywordflow}{if} (!mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_a9777fcaab944e3f170ee6276e6614560}{check\_for\_rst}}(hw, 0) || !mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00618}00618                 mac-\/>\mbox{\hyperlink{structixgbe__mac__info_ac8b44970449576482f75d4a93d811945}{get\_link\_status}} = \textcolor{keyword}{true};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00619}00619 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00620}00620         \textcolor{keywordflow}{if} (!mac-\/>\mbox{\hyperlink{structixgbe__mac__info_ac8b44970449576482f75d4a93d811945}{get\_link\_status}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00621}00621                 \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00622}00622 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00623}00623         \textcolor{comment}{/* if link status is down no point in checking to see if pf is up */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00624}00624         links\_reg = \mbox{\hyperlink{ixgbe__osdep_8h_a11ee885af5408974aefd7faf227166cf}{IXGBE\_READ\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_ac1ba7b349340705b57806db51812288a}{IXGBE\_VFLINKS}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00625}00625         \textcolor{keywordflow}{if} (!(links\_reg \& \mbox{\hyperlink{ixgbe__type_8h_abc5674387627e9283038ace548f9ab8f}{IXGBE\_LINKS\_UP}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00626}00626                 \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00627}00627 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00628}00628         \textcolor{comment}{/* for SFP+ modules and DA cables on 82599 it can take up to 500usecs}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00629}00629 \textcolor{comment}{         * before the link status is correct}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00630}00630 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00631}00631         \textcolor{keywordflow}{if} (mac-\/>\mbox{\hyperlink{structixgbe__mac__info_aad6aed214fb637784ddca4b894c54699}{type}} == \mbox{\hyperlink{ixgbe__type_8h_a054db87ae56dfaeebf448f6925a6123ea3a243937899f54eafd940c67c947c7fc}{ixgbe\_mac\_82599\_vf}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00632}00632                 \textcolor{keywordtype}{int} i;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00633}00633 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00634}00634                 \textcolor{keywordflow}{for} (i = 0; i < 5; i++) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00635}00635                         \mbox{\hyperlink{ixgbe__osdep_8h_a43e7beeb12e2b50153ba0f215b68bb85}{usec\_delay}}(100);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00636}00636                         links\_reg = \mbox{\hyperlink{ixgbe__osdep_8h_a11ee885af5408974aefd7faf227166cf}{IXGBE\_READ\_REG}}(hw, \mbox{\hyperlink{ixgbe__vf_8h_ac1ba7b349340705b57806db51812288a}{IXGBE\_VFLINKS}});}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00637}00637 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00638}00638                         \textcolor{keywordflow}{if} (!(links\_reg \& \mbox{\hyperlink{ixgbe__type_8h_abc5674387627e9283038ace548f9ab8f}{IXGBE\_LINKS\_UP}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00639}00639                                 \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00640}00640                 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00641}00641         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00642}00642 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00643}00643         \textcolor{keywordflow}{switch} (links\_reg \& \mbox{\hyperlink{ixgbe__type_8h_a701b34061a7b57e19ac2bc8fa5a87e66}{IXGBE\_LINKS\_SPEED\_82599}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00644}00644         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__type_8h_a3ca454c5dae1c55cf9fd25b8938710ff}{IXGBE\_LINKS\_SPEED\_10G\_82599}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00645}00645                 *speed = \mbox{\hyperlink{ixgbe__type_8h_aceb965e3452541f5ce4f3ed096181b20}{IXGBE\_LINK\_SPEED\_10GB\_FULL}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00646}00646                 \textcolor{keywordflow}{if} (hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aad6aed214fb637784ddca4b894c54699}{type}} >= \mbox{\hyperlink{ixgbe__type_8h_a054db87ae56dfaeebf448f6925a6123ea2fd88f141bfd346a303a102dfc2e610d}{ixgbe\_mac\_X550}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00647}00647                         \textcolor{keywordflow}{if} (links\_reg \& \mbox{\hyperlink{ixgbe__type_8h_a79011e19e63c3368b438db8802f23c75}{IXGBE\_LINKS\_SPEED\_NON\_STD}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00648}00648                                 *speed = \mbox{\hyperlink{ixgbe__type_8h_ac835a3496b7960da07820f021b10596f}{IXGBE\_LINK\_SPEED\_2\_5GB\_FULL}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00649}00649                 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00650}00650                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00651}00651         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__type_8h_a5e8524f9ead2f1efd870ccce2b7fa332}{IXGBE\_LINKS\_SPEED\_1G\_82599}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00652}00652                 *speed = \mbox{\hyperlink{ixgbe__type_8h_ab51a651866a3834507feb61bcda8b6f5}{IXGBE\_LINK\_SPEED\_1GB\_FULL}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00653}00653                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00654}00654         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__type_8h_aaa5dec5eee331db2483a49d873a796ab}{IXGBE\_LINKS\_SPEED\_100\_82599}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00655}00655                 *speed = \mbox{\hyperlink{ixgbe__type_8h_aa7d867bee1d77f7888ccbc8fc95d7cd1}{IXGBE\_LINK\_SPEED\_100\_FULL}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00656}00656                 \textcolor{keywordflow}{if} (hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aad6aed214fb637784ddca4b894c54699}{type}} == \mbox{\hyperlink{ixgbe__type_8h_a054db87ae56dfaeebf448f6925a6123ea2fd88f141bfd346a303a102dfc2e610d}{ixgbe\_mac\_X550}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00657}00657                         \textcolor{keywordflow}{if} (links\_reg \& \mbox{\hyperlink{ixgbe__type_8h_a79011e19e63c3368b438db8802f23c75}{IXGBE\_LINKS\_SPEED\_NON\_STD}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00658}00658                                 *speed = \mbox{\hyperlink{ixgbe__type_8h_a46f8ca474e574f6830d22bf6711000e1}{IXGBE\_LINK\_SPEED\_5GB\_FULL}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00659}00659                 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00660}00660                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00661}00661         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__type_8h_a64b1988a4fe4de7e15e566dbd6f8d2af}{IXGBE\_LINKS\_SPEED\_10\_X550EM\_A}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00662}00662                 *speed = \mbox{\hyperlink{ixgbe__type_8h_a5bb0051b32feff63b63c0d0057646be7}{IXGBE\_LINK\_SPEED\_UNKNOWN}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00663}00663                 \textcolor{comment}{/* Since Reserved in older MAC's */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00664}00664                 \textcolor{keywordflow}{if} (hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aad6aed214fb637784ddca4b894c54699}{type}} >= \mbox{\hyperlink{ixgbe__type_8h_a054db87ae56dfaeebf448f6925a6123ea2fd88f141bfd346a303a102dfc2e610d}{ixgbe\_mac\_X550}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00665}00665                         *speed = \mbox{\hyperlink{ixgbe__type_8h_a8ac8930d4a373657c5161cc5af22745a}{IXGBE\_LINK\_SPEED\_10\_FULL}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00666}00666                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00667}00667         \textcolor{keywordflow}{default}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00668}00668                 *speed = \mbox{\hyperlink{ixgbe__type_8h_a5bb0051b32feff63b63c0d0057646be7}{IXGBE\_LINK\_SPEED\_UNKNOWN}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00669}00669         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00670}00670 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00671}00671         \textcolor{comment}{/* if the read failed it could just be a mailbox collision, best wait}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00672}00672 \textcolor{comment}{         * until we are called again and don't report an error}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00673}00673 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00674}00674         \textcolor{keywordflow}{if} (mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_af85dc4389d29857cfaeda3dd7532123e}{ops}}.\mbox{\hyperlink{structixgbe__mbx__operations_ae95f6ed6f77a126021b84810b7f345d3}{read}}(hw, \&in\_msg, 1, 0))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00675}00675                 \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00676}00676 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00677}00677         \textcolor{keywordflow}{if} (!(in\_msg \& \mbox{\hyperlink{ixgbe__mbx_8h_ad2d3c35b4b6f5982a3d9e62ad656c2ef}{IXGBE\_VT\_MSGTYPE\_CTS}})) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00678}00678                 \textcolor{comment}{/* msg is not CTS and is NACK we must have lost CTS status */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00679}00679                 \textcolor{keywordflow}{if} (in\_msg \& \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00680}00680                         ret\_val = -\/1;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00681}00681                 \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00682}00682         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00683}00683 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00684}00684         \textcolor{comment}{/* the pf is talking, if we timed out in the past we reinit */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00685}00685         \textcolor{keywordflow}{if} (!mbx-\/>\mbox{\hyperlink{structixgbe__mbx__info_acd335704ec15786ab5a3e2b0b76c3ac3}{timeout}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00686}00686                 ret\_val = -\/1;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00687}00687                 \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00688}00688         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00689}00689 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00690}00690         \textcolor{comment}{/* if we passed all the tests above then the link is up and we no}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00691}00691 \textcolor{comment}{         * longer need to check for link}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00692}00692 \textcolor{comment}{         */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00693}00693         mac-\/>\mbox{\hyperlink{structixgbe__mac__info_ac8b44970449576482f75d4a93d811945}{get\_link\_status}} = \textcolor{keyword}{false};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00694}00694 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00695}00695 out:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00696}00696         *link\_up = !mac-\/>\mbox{\hyperlink{structixgbe__mac__info_ac8b44970449576482f75d4a93d811945}{get\_link\_status}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00697}00697         \textcolor{keywordflow}{return} ret\_val;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00698}00698 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00699}00699 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00705}\mbox{\hyperlink{ixgbe__vf_8c_a79597f3bcdd1d2764662f913888af161}{00705}} \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} \mbox{\hyperlink{ixgbe__vf_8c_a79597f3bcdd1d2764662f913888af161}{ixgbevf\_rlpml\_set\_vf}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \mbox{\hyperlink{ixgbe__osdep_8h_ace9d960e74685e2cd84b36132dbbf8aa}{u16}} max\_size)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00706}00706 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00707}00707         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msgbuf[2];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00708}00708         \mbox{\hyperlink{ixgbe__osdep_8h_ae9b1af5c037e57a98884758875d3a7c4}{s32}} retval;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00709}00709 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00710}00710         msgbuf[0] = \mbox{\hyperlink{ixgbe__mbx_8h_a42a78bbe1a56f86c0802144681244279}{IXGBE\_VF\_SET\_LPE}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00711}00711         msgbuf[1] = max\_size;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00712}00712 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00713}00713         retval = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msgbuf, msgbuf, 2);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00714}00714         \textcolor{keywordflow}{if} (retval)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00715}00715                 \textcolor{keywordflow}{return} retval;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00716}00716         \textcolor{keywordflow}{if} ((msgbuf[0] \& \mbox{\hyperlink{ixgbe__mbx_8h_a42a78bbe1a56f86c0802144681244279}{IXGBE\_VF\_SET\_LPE}}) \&\&}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00717}00717             (msgbuf[0] \& \mbox{\hyperlink{ixgbe__mbx_8h_a43870b24b74d31da14b9d36bdb9fb93a}{IXGBE\_VT\_MSGTYPE\_NACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00718}00718                 \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__mbx_8h_ab7becba651f174dffad1f23cbde2ebf6}{IXGBE\_ERR\_MBX}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00719}00719 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00720}00720         \textcolor{keywordflow}{return} 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00721}00721 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00722}00722 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00728}\mbox{\hyperlink{ixgbe__vf_8c_a2acd56925bcbfa034a2f9e3757c00ed9}{00728}} \textcolor{keywordtype}{int} \mbox{\hyperlink{ixgbe__vf_8c_a2acd56925bcbfa034a2f9e3757c00ed9}{ixgbevf\_negotiate\_api\_version}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \textcolor{keywordtype}{int} api)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00729}00729 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00730}00730         \textcolor{keywordtype}{int} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00731}00731         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msg[3];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00732}00732 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00733}00733         \textcolor{comment}{/* Negotiate the mailbox API version */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00734}00734         msg[0] = \mbox{\hyperlink{ixgbe__mbx_8h_a7a0ed35caf3e20f4fe416da28acad535}{IXGBE\_VF\_API\_NEGOTIATE}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00735}00735         msg[1] = api;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00736}00736         msg[2] = 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00737}00737 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00738}00738         err = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msg, msg, 3);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00739}00739         \textcolor{keywordflow}{if} (!err) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00740}00740                 msg[0] \&= \string~IXGBE\_VT\_MSGTYPE\_CTS;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00741}00741 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00742}00742                 \textcolor{comment}{/* Store value and return 0 on success */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00743}00743                 \textcolor{keywordflow}{if} (msg[0] == (\mbox{\hyperlink{ixgbe__mbx_8h_a7a0ed35caf3e20f4fe416da28acad535}{IXGBE\_VF\_API\_NEGOTIATE}} | \mbox{\hyperlink{ixgbe__mbx_8h_a034f76a9383ab6053fafe5b84b97efea}{IXGBE\_VT\_MSGTYPE\_ACK}})) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00744}00744                         hw-\/>\mbox{\hyperlink{structixgbe__hw_ab3335e18219ea21b8d35c85827d84fad}{api\_version}} = api;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00745}00745                         \textcolor{keywordflow}{return} 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00746}00746                 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00747}00747 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00748}00748                 err = \mbox{\hyperlink{ixgbe__type_8h_aae80aab2def94c1a2e4009c590544b35}{IXGBE\_ERR\_INVALID\_ARGUMENT}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00749}00749         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00750}00750 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00751}00751         \textcolor{keywordflow}{return} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00752}00752 \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00753}00753 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00754}\mbox{\hyperlink{ixgbe__vf_8c_a3d02aa5afd9318b4bb8fd5de970afeac}{00754}} \textcolor{keywordtype}{int} \mbox{\hyperlink{ixgbe__vf_8c_a3d02aa5afd9318b4bb8fd5de970afeac}{ixgbevf\_get\_queues}}(\textcolor{keyword}{struct} \mbox{\hyperlink{structixgbe__hw}{ixgbe\_hw}} *hw, \textcolor{keywordtype}{unsigned} \textcolor{keywordtype}{int} *num\_tcs,}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00755}00755                        \textcolor{keywordtype}{unsigned} \textcolor{keywordtype}{int} *default\_tc)}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00756}00756 \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00757}00757         \textcolor{keywordtype}{int} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00758}00758         \mbox{\hyperlink{ixgbe__osdep_8h_afaa62991928fb9fb18ff0db62a040aba}{u32}} msg[5];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00759}00759 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00760}00760         \textcolor{comment}{/* do nothing if API doesn't support ixgbevf\_get\_queues */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00761}00761         \textcolor{keywordflow}{switch} (hw-\/>\mbox{\hyperlink{structixgbe__hw_ab3335e18219ea21b8d35c85827d84fad}{api\_version}}) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00762}00762         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__mbx_8h_ab1e5ca32b4afa2311aa69df7f103941aa4995c93c914f9f310847303680dd9a3e}{ixgbe\_mbox\_api\_11}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00763}00763         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__mbx_8h_ab1e5ca32b4afa2311aa69df7f103941aa2bee52cfe7c071f801eeab96deee57da}{ixgbe\_mbox\_api\_12}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00764}00764         \textcolor{keywordflow}{case} \mbox{\hyperlink{ixgbe__mbx_8h_ab1e5ca32b4afa2311aa69df7f103941aae0b407460c7b172fb11b665954db7d6e}{ixgbe\_mbox\_api\_13}}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00765}00765                 \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00766}00766         \textcolor{keywordflow}{default}:}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00767}00767                 \textcolor{keywordflow}{return} 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00768}00768         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00769}00769 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00770}00770         \textcolor{comment}{/* Fetch queue configuration from the PF */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00771}00771         msg[0] = \mbox{\hyperlink{ixgbe__mbx_8h_a1b2dca53b14e7c8c5565628ed4e2043a}{IXGBE\_VF\_GET\_QUEUES}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00772}00772         msg[1] = msg[2] = msg[3] = msg[4] = 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00773}00773 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00774}00774         err = \mbox{\hyperlink{ixgbe__vf_8c_a7c2681f0890c3c7b16d6f0d6dc459ea1}{ixgbevf\_write\_msg\_read\_ack}}(hw, msg, msg, 5);}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00775}00775         \textcolor{keywordflow}{if} (!err) \{}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00776}00776                 msg[0] \&= \string~IXGBE\_VT\_MSGTYPE\_CTS;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00777}00777 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00778}00778                 \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00779}00779 \textcolor{comment}{                 * if we we didn't get an ACK there must have been}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00780}00780 \textcolor{comment}{                 * some sort of mailbox error so we should treat it}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00781}00781 \textcolor{comment}{                 * as such}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00782}00782 \textcolor{comment}{                 */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00783}00783                 \textcolor{keywordflow}{if} (msg[0] != (\mbox{\hyperlink{ixgbe__mbx_8h_a1b2dca53b14e7c8c5565628ed4e2043a}{IXGBE\_VF\_GET\_QUEUES}} | \mbox{\hyperlink{ixgbe__mbx_8h_a034f76a9383ab6053fafe5b84b97efea}{IXGBE\_VT\_MSGTYPE\_ACK}}))}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00784}00784                         \textcolor{keywordflow}{return} \mbox{\hyperlink{ixgbe__mbx_8h_ab7becba651f174dffad1f23cbde2ebf6}{IXGBE\_ERR\_MBX}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00785}00785 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00786}00786                 \textcolor{comment}{/* record and validate values from message */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00787}00787                 hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}} = msg[\mbox{\hyperlink{ixgbe__mbx_8h_a53b9e23325bc7802ec964d81d9dccada}{IXGBE\_VF\_TX\_QUEUES}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00788}00788                 \textcolor{keywordflow}{if} (hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}} == 0 ||}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00789}00789                     hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}} > \mbox{\hyperlink{ixgbe__vf_8h_aacc0f62640daf1d0c55fb18c829f9442}{IXGBE\_VF\_MAX\_TX\_QUEUES}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00790}00790                         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}} = \mbox{\hyperlink{ixgbe__vf_8h_aacc0f62640daf1d0c55fb18c829f9442}{IXGBE\_VF\_MAX\_TX\_QUEUES}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00791}00791 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00792}00792                 hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}} = msg[\mbox{\hyperlink{ixgbe__mbx_8h_a67d28b8c14289f579997a46b364abc4d}{IXGBE\_VF\_RX\_QUEUES}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00793}00793                 \textcolor{keywordflow}{if} (hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}} == 0 ||}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00794}00794                     hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}} > \mbox{\hyperlink{ixgbe__vf_8h_a7f7fdb4b7cb245fe291337d647746edf}{IXGBE\_VF\_MAX\_RX\_QUEUES}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00795}00795                         hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}} = \mbox{\hyperlink{ixgbe__vf_8h_a7f7fdb4b7cb245fe291337d647746edf}{IXGBE\_VF\_MAX\_RX\_QUEUES}};}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00796}00796 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00797}00797                 *num\_tcs = msg[\mbox{\hyperlink{ixgbe__mbx_8h_ac9ea050700b0e89aec46b362a76d88e4}{IXGBE\_VF\_TRANS\_VLAN}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00798}00798                 \textcolor{comment}{/* in case of unknown state assume we cannot tag frames */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00799}00799                 \textcolor{keywordflow}{if} (*num\_tcs > hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_aedf51ba2d3a921e8cc9e8d5ce05b358d}{max\_rx\_queues}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00800}00800                         *num\_tcs = 1;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00801}00801 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00802}00802                 *default\_tc = msg[\mbox{\hyperlink{ixgbe__mbx_8h_a91ec20164c4b0337368ff6e78ba537b3}{IXGBE\_VF\_DEF\_QUEUE}}];}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00803}00803                 \textcolor{comment}{/* default to queue 0 on out-\/of-\/bounds queue number */}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00804}00804                 \textcolor{keywordflow}{if} (*default\_tc >= hw-\/>\mbox{\hyperlink{structixgbe__hw_a2c77aedc92d6ba10dec6b4536d5af587}{mac}}.\mbox{\hyperlink{structixgbe__mac__info_a539aca02bc3667746406e9821dcd43ea}{max\_tx\_queues}})}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00805}00805                         *default\_tc = 0;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00806}00806         \}}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00807}00807 }
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00808}00808         \textcolor{keywordflow}{return} err;}
\DoxyCodeLine{\Hypertarget{ixgbe__vf_8c_source_l00809}00809 \}}

\end{DoxyCode}
