Commit 93b7654e authored by Stanislaw Gruszka's avatar Stanislaw Gruszka Committed by John W. Linville
Browse files

iwlegacy: move debugfs_ops to il_priv

parent 3dfea27d
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -503,3 +503,9 @@ il3945_ucode_general_stats_read(struct file *file, char __user *user_buf,
	kfree(buf);
	return ret;
}

const struct il_debugfs_ops il3945_debugfs_ops = {
	.rx_stats_read = il3945_ucode_rx_stats_read,
	.tx_stats_read = il3945_ucode_tx_stats_read,
	.general_stats_read = il3945_ucode_general_stats_read,
};
+3 −0
Original line number Diff line number Diff line
@@ -3619,6 +3619,9 @@ il3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
	D_INFO("*** LOAD DRIVER ***\n");
	il->cfg = cfg;
	il->ops = &il3945_ops;
#ifdef CONFIG_IWLEGACY_DEBUGFS
	il->debugfs_ops = &il3945_debugfs_ops;
#endif
	il->pci_dev = pdev;
	il->inta_mask = CSR_INI_SET_MASK;

+0 −8
Original line number Diff line number Diff line
@@ -2651,14 +2651,6 @@ static struct il_lib_ops il3945_lib = {
	},
	.send_tx_power = il3945_send_tx_power,
	.is_valid_rtc_data_addr = il3945_hw_valid_rtc_data_addr,

#ifdef CONFIG_IWLEGACY_DEBUGFS
	.debugfs_ops = {
			.rx_stats_read = il3945_ucode_rx_stats_read,
			.tx_stats_read = il3945_ucode_tx_stats_read,
			.general_stats_read = il3945_ucode_general_stats_read,
			},
#endif
};

static const struct il_legacy_ops il3945_legacy_ops = {
+1 −7
Original line number Diff line number Diff line
@@ -595,13 +595,7 @@ struct il3945_tfd {
} __packed;

#ifdef CONFIG_IWLEGACY_DEBUGFS
ssize_t il3945_ucode_rx_stats_read(struct file *file, char __user *user_buf,
				   size_t count, loff_t *ppos);
ssize_t il3945_ucode_tx_stats_read(struct file *file, char __user *user_buf,
				   size_t count, loff_t *ppos);
ssize_t il3945_ucode_general_stats_read(struct file *file,
					char __user *user_buf, size_t count,
					loff_t *ppos);
extern const struct il_debugfs_ops il3945_debugfs_ops;
#endif

#endif
+6 −0
Original line number Diff line number Diff line
@@ -744,3 +744,9 @@ il4965_ucode_general_stats_read(struct file *file, char __user *user_buf,
	kfree(buf);
	return ret;
}

const struct il_debugfs_ops il4965_debugfs_ops = {
	.rx_stats_read = il4965_ucode_rx_stats_read,
	.tx_stats_read = il4965_ucode_tx_stats_read,
	.general_stats_read = il4965_ucode_general_stats_read,
};
Loading