Date: Thu, 13 Dec 2012 03:33:02 +0000 (UTC) From: Oleksandr Tymoshenko <gonzo@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r244169 - head/sys/dev/smc Message-ID: <201212130333.qBD3X25Y028990@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: gonzo Date: Thu Dec 13 03:33:01 2012 New Revision: 244169 URL: http://svnweb.freebsd.org/changeset/base/244169 Log: Disable interrupts in filter in order to avoid interrupt storm and CPU starvation Modified: head/sys/dev/smc/if_smc.c Modified: head/sys/dev/smc/if_smc.c ============================================================================== --- head/sys/dev/smc/if_smc.c Thu Dec 13 02:21:05 2012 (r244168) +++ head/sys/dev/smc/if_smc.c Thu Dec 13 03:33:01 2012 (r244169) @@ -807,6 +807,10 @@ smc_intr(void *context) struct smc_softc *sc; sc = (struct smc_softc *)context; + /* + * Block interrupts in order to let smc_task_intr to kick in + */ + smc_write_1(sc, MSK, 0); taskqueue_enqueue_fast(sc->smc_tq, &sc->smc_intr); return (FILTER_HANDLED); } @@ -827,13 +831,6 @@ smc_task_intr(void *context, int pending smc_select_bank(sc, 2); /* - * Get the current mask, and then block all interrupts while we're - * working. - */ - if ((ifp->if_capenable & IFCAP_POLLING) == 0) - smc_write_1(sc, MSK, 0); - - /* * Find out what interrupts are flagged. */ status = smc_read_1(sc, IST) & sc->smc_mask;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201212130333.qBD3X25Y028990>