/* This routine detaches and shuts down a KS8695 ethernet device.  */
static int ks8695_drv_suspend(struct platform_device *pdev, pm_message_t state)
/* This routine detaches and shuts down a KS8695 ethernet device.  */
static int ks8695_drv_suspend(struct platform_device *pdev, pm_message_t state)
{
	struct net_device *ndev = platform_get_drvdata(pdev);
	struct ks8695_priv *ksp = netdev_priv(ndev);
	ksp->in_suspend = 1;
	if (netif_running(ndev)) {
		netif_device_detach(ndev);
		ks8695_shutdown(ksp);
	}
	return 0;
}