Skip to content

Commit

Permalink
Merge pull request #448 from ipatrykx/fix-linter-issues
Browse files Browse the repository at this point in the history
Fixed linter issues
  • Loading branch information
adrianchiris authored Nov 21, 2022
2 parents fc8984c + 0e0e36b commit afa0410
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 8 deletions.
4 changes: 2 additions & 2 deletions pkg/netdevice/netInfoProviders.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import (
)

/*
rdmaInfoProvider provides the RDMA information
rdmaInfoProvider provides the RDMA information
*/
type rdmaInfoProvider struct {
rdmaSpec types.RdmaSpec
Expand Down Expand Up @@ -58,7 +58,7 @@ func (rip *rdmaInfoProvider) GetMounts() []*pluginapi.Mount {
}

/*
VhostNetInfoProvider wraps any DeviceInfoProvider and adds a vhost-net device
VhostNetInfoProvider wraps any DeviceInfoProvider and adds a vhost-net device
*/
type vhostNetInfoProvider struct {
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/netdevice/netResourcePool.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ func (rp *netResourcePool) GetDeviceSpecs(deviceIDs []string) []*pluginapi.Devic
}

// StoreDeviceInfoFile stores the Device Info files according to the
// k8snetworkplumbingwg/device-info-spec
// k8snetworkplumbingwg/device-info-spec
func (rp *netResourcePool) StoreDeviceInfoFile(resourceNamePrefix string) error {
var devInfo nettypes.DeviceInfo
for id, dev := range rp.GetDevicePool() {
Expand Down
5 changes: 3 additions & 2 deletions pkg/netdevice/vdpa.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,9 @@ import (
"github.com/k8snetworkplumbingwg/sriov-network-device-plugin/pkg/utils"
)

/*vdpaTypeToDriver translates vdpaTypes (as specified in the netDevice selectors)
to vdpa bus drivers*/
// vdpaTypeToDriver translates vdpaTypes (as specified in the netDevice selectors)
// to vdpa bus drivers

var supportedVdpaTypes = map[types.VdpaType]string{
types.VdpaVirtioType: vdpa.VirtioVdpaDriver,
types.VdpaVhostType: vdpa.VhostVdpaDriver,
Expand Down
2 changes: 1 addition & 1 deletion pkg/resources/vfioInfoProvider.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
)

/*
vfioInfoProvider implements DeviceInfoProvider
vfioInfoProvider implements DeviceInfoProvider
*/
type vfioInfoProvider struct {
pciAddr string
Expand Down
4 changes: 2 additions & 2 deletions pkg/utils/ddp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
. "github.com/onsi/gomega"
)

//https://npf.io/2015/06/testing-exec-command
// https://npf.io/2015/06/testing-exec-command
func FakeExecCommand(outs, exitCode string) func(string, ...string) *exec.Cmd {
return func(command string, args ...string) *exec.Cmd {
cs := []string{"-test.run=TestHelperProcess", "--", command}
Expand All @@ -25,7 +25,7 @@ func FakeExecCommand(outs, exitCode string) func(string, ...string) *exec.Cmd {
}
}

//https://npf.io/2015/06/testing-exec-command
// https://npf.io/2015/06/testing-exec-command
func TestHelperProcess(t *testing.T) {
if os.Getenv("GO_WANT_HELPER_PROCESS") != "1" {
return
Expand Down

0 comments on commit afa0410

Please sign in to comment.